提交 24724288 编写于 作者: S Sebastian Martinez

Remove extra whitespaces.

上级 31110c50
......@@ -9,8 +9,8 @@ class InvalidRequestError < StandardError; end #:nodoc:
# requests.
#
# To test your Active Resource model, you simply call the ActiveResource::HttpMock.respond_to
# method with an attached block. The block declares a set of URIs with expected input, and the output
# each request should return. The passed in block has any number of entries in the following generalized
# method with an attached block. The block declares a set of URIs with expected input, and the output
# each request should return. The passed in block has any number of entries in the following generalized
# format:
#
# mock.http_method(path, request_headers = {}, body = nil, status = 200, response_headers = {})
......@@ -29,7 +29,7 @@ class InvalidRequestError < StandardError; end #:nodoc:
# <tt>request_headers</tt> listed above.
#
# In order for a mock to deliver its content, the incoming request must match by the <tt>http_method</tt>,
# +path+ and <tt>request_headers</tt>. If no match is found an InvalidRequestError exception
# +path+ and <tt>request_headers</tt>. If no match is found an +InvalidRequestError+ exception
# will be raised showing you what request it could not find a response for and also what requests and response
# pairs have been recorded so you can create a new mock for that request.
#
......@@ -80,7 +80,7 @@ def delete_duplicate_responses(request)
class << self
# Returns an array of all request objects that have been sent to the mock. You can use this to check
# Returns an array of all request objects that have been sent to the mock. You can use this to check
# if your model actually sent an HTTP request.
#
# ==== Example
......@@ -105,7 +105,7 @@ def requests
end
# Returns the list of requests and their mocked responses. Look up a
# response for a request using responses.assoc(request).
# response for a request using <tt>responses.assoc(request)</tt>.
def responses
@@responses ||= []
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册