Validates the arguments when queueing a job with Resque. Rather than getting an ArgumentError in the job, you get it at the point the job is queued.
NB: We only load this gem into the test environment, so these errors aren't raised in production.
Add this line to your application's Gemfile:
gem 'resque-enqueue-arity'
And then execute:
$ bundle
Or install it yourself as:
$ gem install resque-enqueue-arity
Just require it, and it's live. Inspects the number of arguments a job requires on-the-fly, so no dev intervention is required.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Added some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request