Class: WsdlMapperTesting::Middlewares::FakeDispatcher
- Inherits:
-
Object
- Object
- WsdlMapperTesting::Middlewares::FakeDispatcher
- Defined in:
- lib/wsdl_mapper_testing/middlewares/fake_dispatcher.rb
Instance Method Summary collapse
- #call(operation, request) ⇒ Object
- #fake_request(request, http_response) ⇒ Object
-
#initialize ⇒ FakeDispatcher
constructor
A new instance of FakeDispatcher.
Constructor Details
#initialize ⇒ FakeDispatcher
Returns a new instance of FakeDispatcher.
4 5 6 |
# File 'lib/wsdl_mapper_testing/middlewares/fake_dispatcher.rb', line 4 def initialize @requests = {} end |
Instance Method Details
#call(operation, request) ⇒ Object
12 13 14 |
# File 'lib/wsdl_mapper_testing/middlewares/fake_dispatcher.rb', line 12 def call(operation, request) [operation, request, @requests[request]] end |
#fake_request(request, http_response) ⇒ Object
8 9 10 |
# File 'lib/wsdl_mapper_testing/middlewares/fake_dispatcher.rb', line 8 def fake_request(request, http_response) @requests[request] = http_response end |