title: Writing tests for a sidekiq worker
body: <p>I am using the <code>rspec-sidekiq</code> gem (<a href="https://github.com/philostler/rspec-sidekiq">https://github.com/philostler/rspec-sidekiq</a>) to help test a worker I am writing, but for some reason my test keeps failing.</p>
  
  <p>Here is my Test:</p>
  
  <pre><code>require 'spec_helper'
  
  describe CommunicationWorker do
    it { should be_retryable false }
  
    it "enqueues a communication worker" do
      subject.perform("foo@bar.com", "bar@foo.com", [1,2,3])
      expect(CommunicationWorker).to have_enqueued_jobs(1)
    end
  end
  </code></pre>
  
  <p>Here is the error:</p>
  
  <pre><code> 1) CommunicationWorker enqueues a communication worker
       Failure/Error: expect(CommunicationWorker).to have_enqueued_jobs(1)
         expected CommunicationWorker to have 1 enqueued job but got 0
       # ./spec/workers/communication_worker_spec.rb:9:in `block (2 levels) in &lt;top (required)&gt;'
  </code></pre>
  
  <p>I based my low-level test off of their example on their wiki, but it's not working for me... any reason why this wouldn't work?</p>