Skip to content

Conversation

@p-schlickmann
Copy link
Contributor

Issue: #602

Attempting to fix the latest flake against main


test "starting and stopping a worker emits register_process and deregister_process events" do
StoreResultJob.perform_later(42, pause: SolidQueue.shutdown_timeout + 100.second)
StoreResultJob.perform_later(42, pause: SolidQueue.shutdown_timeout + 15.seconds)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not related to scheduler_test, but I don't think this is ever a good idea, to have a timeout that long 😅


unless self.class.use_transactional_tests
destroy_records
end
Copy link
Contributor Author

@p-schlickmann p-schlickmann Nov 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In theory, destroy_records will always run in teardown, even if a test fails.

But I also added it in setup to be extra sure records aren't leaking between tests, if for some reason teardown can't run because of a deadlock or a :KILL signal

Copy link

@rafael-pissardo rafael-pissardo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants