sqlite3-ruby icon indicating copy to clipboard operation
sqlite3-ruby copied to clipboard

Revive test_busy_handler_outwait and synchronize threads to remove "sleep 1".

Open masamitsu-murase opened this issue 1 year ago • 1 comments

I revived test_busy_handler_outwait because I think that this test covers a good use case regarding busy_handler.

Ruby 1.9 and later does not allow a thread to unlock a Mutex locked by another thread, so I used Queue to synchronize the main thread and another thread. I also refined other test methods to remove sleep 1, which was used to synchronize threads.

I hope this pull request improves this project, but please feel free to ignore it if it is not so useful.

Regards, Murase

masamitsu-murase avatar Jan 08 '24 06:01 masamitsu-murase

Speeding up the test suite is a nice feature. I've been running the whole suite locally a lot lately, and these tests are very noticeable.

fractaledmind avatar Jan 12 '24 09:01 fractaledmind

I've rebased this onto current main

flavorjones avatar Apr 25 '24 15:04 flavorjones

MacOS failures are unrelated, merging. @masamitsu-murase Thank you!

flavorjones avatar Apr 25 '24 16:04 flavorjones