gitlab-org--gitlab-foss/spec/support/helpers/stub_worker.rb
2019-07-25 17:33:34 +12:00

11 lines
264 B
Ruby

# frozen_string_literal: true
# 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