debian-mirror-gitlab/spec/support/helpers/stub_worker.rb

10 lines
233 B
Ruby
Raw Normal View History

2019-05-18 00:54:41 +05:30
# Inspired by https://github.com/ljkbennett/stub_env/blob/master/lib/stub_env/helpers.rb
module StubWorker
def stub_worker(queue:)
Class.new do
include Sidekiq::Worker
sidekiq_options queue: queue
end
end
end