Permalink
Browse files

HttpMock InvalidRequestError inspects the mismatched request

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5768 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent e6988ef commit 8cb6cb58a29b422ab7d2f2917262e40ec340816d @jeremy jeremy committed Dec 21, 2006
Showing with 2 additions and 2 deletions.
  1. +2 −2 activeresource/lib/active_resource/http_mock.rb
View
4 activeresource/lib/active_resource/http_mock.rb
@@ -46,7 +46,7 @@ def reset!
def #{method}(path, body, headers)
request = ActiveResource::Request.new(:#{method}, path, body, headers)
self.class.requests << request
- self.class.responses[request] || raise(InvalidRequestError.new("No response recorded for: \#{request}"))
+ self.class.responses[request] || raise(InvalidRequestError.new("No response recorded for: \#{request.inspect}"))
end
EOE
end
@@ -56,7 +56,7 @@ def #{method}(path, body, headers)
def #{method}(path, headers)
request = ActiveResource::Request.new(:#{method}, path, nil, headers)
self.class.requests << request
- self.class.responses[request] || raise(InvalidRequestError.new("No response recorded for: \#{request}"))
+ self.class.responses[request] || raise(InvalidRequestError.new("No response recorded for: \#{request.inspect}"))
end
EOE
end

0 comments on commit 8cb6cb5

Please sign in to comment.