Sha256: 3f2d2f6f5a4d4cc9d119077571c5f62c161c0d0e029fdf6cb40c9d899845ccf0
Contents?: true
Size: 495 Bytes
Versions: 3
Compression:
Stored size: 495 Bytes
Contents
# encoding: utf-8 def mock_offer(id = nil, headers = {}) id ||= rand double("Offer: #{id}").tap do |offer| allow(offer).to receive_messages :call_id => id, :headers => headers offer.as_null_object end end module HasMockCallbackConnection def self.included(test_case) test_case.let(:connection) do double('Connection').tap do |mc| allow(mc).to receive :handle_event do |event| original_command.add_event event end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
adhearsion-3.0.0.rc1 | spec/support/punchblock_mocks.rb |
adhearsion-3.0.0.beta2 | spec/support/punchblock_mocks.rb |
adhearsion-3.0.0.beta1 | spec/support/punchblock_mocks.rb |