Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add test for clear in ActionDispatch::Request::Session

  • Loading branch information...
commit 207bad422b136211fb5d644e65e7a488ab4ac846 1 parent f415475
@alup alup authored
Showing with 9 additions and 0 deletions.
  1. +9 −0 actionpack/test/dispatch/request/session_test.rb
View
9 actionpack/test/dispatch/request/session_test.rb
@@ -52,6 +52,15 @@ def test_values
assert_equal %w[ftw awesome], s.values
end
+ def test_clear
+ env = {}
+ s = Session.create(store, env, {})
+ s['rails'] = 'ftw'
+ s['adequate'] = 'awesome'
+ s.clear
+ assert_equal([], s.values)
+ end
+
private
def store
Class.new {
Please sign in to comment.
Something went wrong with that request. Please try again.