aboutsummaryrefslogtreecommitdiffstats
path: root/activeresource
diff options
context:
space:
mode:
authorRick Olson <technoweenie@gmail.com>2006-10-02 14:20:18 +0000
committerRick Olson <technoweenie@gmail.com>2006-10-02 14:20:18 +0000
commit163a7123e5d68ebde0cb80685a9584662cdf4ad3 (patch)
tree850a18e4ba84e4e6221fd4a7bdbf3f32082ecdf9 /activeresource
parentef4fb3dee2e897b245ee6f545232378db3de7b38 (diff)
downloadrails-163a7123e5d68ebde0cb80685a9584662cdf4ad3.tar.gz
rails-163a7123e5d68ebde0cb80685a9584662cdf4ad3.tar.bz2
rails-163a7123e5d68ebde0cb80685a9584662cdf4ad3.zip
assume the passed headers to the ActiveResource HttpMock Request/Response are hashes [Rick Olson]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5216 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activeresource')
-rw-r--r--activeresource/test/http_mock.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activeresource/test/http_mock.rb b/activeresource/test/http_mock.rb
index 66351501d9..1166a56af7 100644
--- a/activeresource/test/http_mock.rb
+++ b/activeresource/test/http_mock.rb
@@ -69,7 +69,7 @@ module ActiveResource
class Request
attr_accessor :path, :method, :body, :headers
- def initialize(method, path, body = nil, headers = nil)
+ def initialize(method, path, body = nil, headers = {})
@method, @path, @body, @headers = method, path, body, headers
@headers.update('Content-Type' => 'application/xml')
end
@@ -94,7 +94,7 @@ module ActiveResource
class Response
attr_accessor :body, :code, :headers
- def initialize(body, code = 200, headers = nil)
+ def initialize(body, code = 200, headers = {})
@body, @code, @headers = body, code, headers
end