aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/generators/namespaced_generators_test.rb
diff options
context:
space:
mode:
authorAbdelkader Boudih <terminale@gmail.com>2015-10-27 00:41:27 +0000
committereileencodes <eileencodes@gmail.com>2015-12-15 15:19:16 -0500
commit98a039dcd987fd3a8c2c0cbd527c71ac3ffaaf06 (patch)
tree9a9c694ad27af05f600a74d58d8727ac795a2b85 /railties/test/generators/namespaced_generators_test.rb
parentf8edd2043e864aff0bde9289da550709532268a6 (diff)
downloadrails-98a039dcd987fd3a8c2c0cbd527c71ac3ffaaf06.tar.gz
rails-98a039dcd987fd3a8c2c0cbd527c71ac3ffaaf06.tar.bz2
rails-98a039dcd987fd3a8c2c0cbd527c71ac3ffaaf06.zip
Update test generators to use ActionDispatch::IntegrationTest
In Rails 5.1 `ActionController::TestCase` will be moved out of Rails into it's own gem. Please use `ActionDispatch::IntegrationTest` going forward. This changes the generators to use `ActionDispatch::IntegrationTest` and the required URL setup (rather than symbols) for each of the controller actions. Updated fix to #22076.
Diffstat (limited to 'railties/test/generators/namespaced_generators_test.rb')
-rw-r--r--railties/test/generators/namespaced_generators_test.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/railties/test/generators/namespaced_generators_test.rb b/railties/test/generators/namespaced_generators_test.rb
index 918faae74b..d76759a7d1 100644
--- a/railties/test/generators/namespaced_generators_test.rb
+++ b/railties/test/generators/namespaced_generators_test.rb
@@ -218,7 +218,7 @@ class NamespacedScaffoldGeneratorTest < NamespacedGeneratorTestCase
/class ProductLinesController < ApplicationController/
assert_file "test/controllers/test_app/product_lines_controller_test.rb",
- /module TestApp\n class ProductLinesControllerTest < ActionController::TestCase/
+ /module TestApp\n class ProductLinesControllerTest < ActionDispatch::IntegrationTest/
# Views
%w(index edit new show _form).each do |view|
@@ -285,7 +285,7 @@ class NamespacedScaffoldGeneratorTest < NamespacedGeneratorTestCase
end
assert_file "test/controllers/test_app/admin/roles_controller_test.rb",
- /module TestApp\n class Admin::RolesControllerTest < ActionController::TestCase/
+ /module TestApp\n class Admin::RolesControllerTest < ActionDispatch::IntegrationTest/
# Views
%w(index edit new show _form).each do |view|
@@ -352,7 +352,7 @@ class NamespacedScaffoldGeneratorTest < NamespacedGeneratorTestCase
end
assert_file "test/controllers/test_app/admin/user/special/roles_controller_test.rb",
- /module TestApp\n class Admin::User::Special::RolesControllerTest < ActionController::TestCase/
+ /module TestApp\n class Admin::User::Special::RolesControllerTest < ActionDispatch::IntegrationTest/
# Views
%w(index edit new show _form).each do |view|
@@ -418,6 +418,6 @@ class NamespacedScaffoldGeneratorTest < NamespacedGeneratorTestCase
assert_match(%r(require_dependency "test_app/application_controller"), content)
end
assert_file "test/controllers/test_app/admin/roles_controller_test.rb",
- /module TestApp\n class Admin::RolesControllerTest < ActionController::TestCase/
+ /module TestApp\n class Admin::RolesControllerTest < ActionDispatch::IntegrationTest/
end
end