title: Test if a block is passed with RSpec Mocks
body: <p>I can test if arguments are passed like:</p>
  
  <pre><code>RSpec.describe do
    it do
      obj = double
      expect(obj).to receive(:method).with(1, 2, 3)
      obj.method(1, 2, 3)
    end
  end
  </code></pre>
  
  <p>How should I do about a block parameter?  My ideal code:</p>
  
  <pre><code>RSpec.describe do
    it do
      obj = double
      proc = Proc.new{}
      expect(obj).to receive(:method).with(1, 2, 3).with_block(proc)
      obj.method(1, 2, 3, &amp;proc)
    end
  end
  </code></pre>