A
A
Anton Ivanov2017-01-11 13:27:26
Ruby on Rails
Anton Ivanov, 2017-01-11 13:27:26

How to get the job structure in rspec, which is passed to ActiveJob?

Hello.
In the test, I check that the task was scheduled:
expect(JobNameJob).to have_been_enqueued
The task leaves the task structure, the field values ​​​​of which are dynamic (in particular, file names are formed based on unix timestamp)
have_been_enqueued.with all required keys were present and all had the required type + filled value. The value itself does not need to be checked. How can I do that?
Thank you.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question