File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ class InstrumentationTest < ActiveSupport::TestCase
5353 end
5454
5555 test "stopping a worker with claimed executions emits release_claimed events" do
56- StoreResultJob . perform_later ( 42 , pause : SolidQueue . shutdown_timeout + 100 . second )
56+ StoreResultJob . perform_later ( 42 , pause : SolidQueue . shutdown_timeout + 10 . seconds )
5757 process = nil
5858
5959 events = subscribed ( /release.*_claimed\. solid_queue/ ) do
@@ -88,7 +88,7 @@ class InstrumentationTest < ActiveSupport::TestCase
8888 end
8989
9090 test "starting and stopping a worker emits register_process and deregister_process events" do
91- StoreResultJob . perform_later ( 42 , pause : SolidQueue . shutdown_timeout + 100 . second )
91+ StoreResultJob . perform_later ( 42 , pause : SolidQueue . shutdown_timeout + 10 . seconds )
9292 process = nil
9393
9494 events = subscribed ( /(register|deregister)_process\. solid_queue/ ) do
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ class SchedulerTest < ActiveSupport::TestCase
2424 end
2525
2626 schedulers . each ( &:start )
27- sleep 2
27+ wait_while_with_timeout ( 2.5 . seconds ) { SolidQueue :: RecurringExecution . count != 2 }
2828 schedulers . each ( &:stop )
2929
3030 assert_equal SolidQueue ::Job . count , SolidQueue ::RecurringExecution . count
You can’t perform that action at this time.
0 commit comments