diff options
author | Andrew White <andyw@pixeltrix.co.uk> | 2011-03-06 12:49:44 +0000 |
---|---|---|
committer | Andrew White <andyw@pixeltrix.co.uk> | 2011-03-06 12:49:44 +0000 |
commit | 31f09f9dbc1b8e598fc82d86b622167bfc01d18a (patch) | |
tree | 8568ac4781f047ab912f873b226ac4ee13df7717 /actionpack/lib/action_dispatch/testing/test_process.rb | |
parent | e00867bc437b6a681491ef59e13423051e6d98f0 (diff) | |
download | rails-31f09f9dbc1b8e598fc82d86b622167bfc01d18a.tar.gz rails-31f09f9dbc1b8e598fc82d86b622167bfc01d18a.tar.bz2 rails-31f09f9dbc1b8e598fc82d86b622167bfc01d18a.zip |
Improve testing of cookies in functional tests:
- cookies can be set using string or symbol keys
- cookies are preserved across calls to get, post, etc.
- cookie names and values are escaped
- cookies can be cleared using @request.cookies.clear
[#6272 state:resolved]
Diffstat (limited to 'actionpack/lib/action_dispatch/testing/test_process.rb')
-rw-r--r-- | actionpack/lib/action_dispatch/testing/test_process.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/testing/test_process.rb b/actionpack/lib/action_dispatch/testing/test_process.rb index 16f3674164..d430691429 100644 --- a/actionpack/lib/action_dispatch/testing/test_process.rb +++ b/actionpack/lib/action_dispatch/testing/test_process.rb @@ -22,7 +22,7 @@ module ActionDispatch end def cookies - HashWithIndifferentAccess.new(@request.cookies.merge(@response.cookies)) + @request.cookies.merge(@response.cookies).with_indifferent_access end def redirect_to_url |