aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/flash_test.rb
diff options
context:
space:
mode:
authorRafael França <rafaelmfranca@gmail.com>2019-01-17 17:12:57 -0500
committerGitHub <noreply@github.com>2019-01-17 17:12:57 -0500
commite65a3a0ce585b1fbcd35872616717595d6950fca (patch)
treef1373015e625acc65fd0997cbf61a2a63e1b6720 /actionpack/test/controller/flash_test.rb
parentcc0dd1d371868fe34fba6b58d22a8ba0714d8ae7 (diff)
parent4d51efe24e461a2a3ed562787308484cd48370c7 (diff)
downloadrails-e65a3a0ce585b1fbcd35872616717595d6950fca.tar.gz
rails-e65a3a0ce585b1fbcd35872616717595d6950fca.tar.bz2
rails-e65a3a0ce585b1fbcd35872616717595d6950fca.zip
Merge pull request #34954 from rails/rm-remove-5.2-deprecations
Remove all code deprecated in Rails 5.2
Diffstat (limited to 'actionpack/test/controller/flash_test.rb')
-rw-r--r--actionpack/test/controller/flash_test.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/actionpack/test/controller/flash_test.rb b/actionpack/test/controller/flash_test.rb
index 409a4ec2e6..bf95c633e5 100644
--- a/actionpack/test/controller/flash_test.rb
+++ b/actionpack/test/controller/flash_test.rb
@@ -242,8 +242,11 @@ end
class FlashIntegrationTest < ActionDispatch::IntegrationTest
SessionKey = "_myapp_session"
- Generator = ActiveSupport::LegacyKeyGenerator.new("b3c631c314c0bbca50c1b2843150fe33")
- Rotations = ActiveSupport::Messages::RotationConfiguration.new
+ Generator = ActiveSupport::CachingKeyGenerator.new(
+ ActiveSupport::KeyGenerator.new("b3c631c314c0bbca50c1b2843150fe33", iterations: 1000)
+ )
+ Rotations = ActiveSupport::Messages::RotationConfiguration.new
+ SIGNED_COOKIE_SALT = "signed cookie"
class TestController < ActionController::Base
add_flash_types :bar
@@ -365,6 +368,7 @@ class FlashIntegrationTest < ActionDispatch::IntegrationTest
args[0][:env] ||= {}
args[0][:env]["action_dispatch.key_generator"] ||= Generator
args[0][:env]["action_dispatch.cookies_rotations"] = Rotations
+ args[0][:env]["action_dispatch.signed_cookie_salt"] = SIGNED_COOKIE_SALT
super(path, *args)
end