method
assert_performed_with
v5.0.0.1 -
Show latest stable
- Class:
ActiveJob::TestHelper
assert_performed_with(args = {})public
Asserts that the job passed in the block has been performed with the given arguments.
def test_assert_performed_with assert_performed_with(job: MyJob, args: [1,2,3], queue: 'high') do MyJob.perform_later(1,2,3) end assert_performed_with(job: MyJob, at: Date.tomorrow.noon) do MyJob.set(wait_until: Date.tomorrow.noon).perform_later end end