diff options
author | Kasper Timm Hansen <kaspth@gmail.com> | 2015-12-13 20:57:51 +0100 |
---|---|---|
committer | Kasper Timm Hansen <kaspth@gmail.com> | 2015-12-13 20:57:51 +0100 |
commit | 02eef9459a19f263b30d8d032017c05bfc97d00b (patch) | |
tree | a30e1cb03416c712b412f495358b0fbc1a65e14a /railties/test/generators | |
parent | 8404aa2a72a1aa03b6177d00c21612f09f23b8c8 (diff) | |
parent | c83ace7b6a5720be30a2f7d843d545fc81af54cd (diff) | |
download | rails-02eef9459a19f263b30d8d032017c05bfc97d00b.tar.gz rails-02eef9459a19f263b30d8d032017c05bfc97d00b.tar.bz2 rails-02eef9459a19f263b30d8d032017c05bfc97d00b.zip |
Merge pull request #22574 from gsamokovarov/scaffold-500
Prevent a 500 in the default controller scaffold
Diffstat (limited to 'railties/test/generators')
-rw-r--r-- | railties/test/generators/scaffold_controller_generator_test.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/test/generators/scaffold_controller_generator_test.rb b/railties/test/generators/scaffold_controller_generator_test.rb index 95ef853a11..b4ba101017 100644 --- a/railties/test/generators/scaffold_controller_generator_test.rb +++ b/railties/test/generators/scaffold_controller_generator_test.rb @@ -56,7 +56,7 @@ class ScaffoldControllerGeneratorTest < Rails::Generators::TestCase assert_file "app/controllers/users_controller.rb" do |content| assert_match(/def user_params/, content) - assert_match(/params\[:user\]/, content) + assert_match(/params\.fetch\(:user, \{\}\)/, content) end end |