Skip to content

Commit

Permalink
Fix test_session_store_with_expire_after failure with rack-test 0.7.1
Browse files Browse the repository at this point in the history
  • Loading branch information
kamipo committed Nov 19, 2017
1 parent 1a0f85e commit bc27697
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Expand Up @@ -371,7 +371,7 @@ GEM
rack (>= 0.4)
rack-protection (2.0.0)
rack
rack-test (0.7.0)
rack-test (0.7.1)
rack (>= 1.0, < 3)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
Expand Down
4 changes: 2 additions & 2 deletions actionpack/test/dispatch/session/cookie_store_test.rb
Expand Up @@ -283,8 +283,6 @@ def test_session_store_with_expire_after
with_test_route_set(expire_after: 5.hours) do
# First request accesses the session
time = Time.local(2008, 4, 24)
cookie_body = nil

Time.stub :now, time do
expected_expiry = (time + 5.hours).gmtime.strftime("%a, %d %b %Y %H:%M:%S -0000")

Expand All @@ -303,6 +301,8 @@ def test_session_store_with_expire_after
Time.stub :now, time do
expected_expiry = (time + 5.hours).gmtime.strftime("%a, %d %b %Y %H:%M:%S -0000")

cookies[SessionKey] = SignedBar

get "/no_session_access"
assert_response :success

Expand Down

0 comments on commit bc27697

Please sign in to comment.