aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test
diff options
context:
space:
mode:
authorJey Balachandran <jey.balachandran@gmail.com>2015-12-18 22:32:06 -0500
committerJey Balachandran <jey.balachandran@gmail.com>2015-12-21 15:27:42 -0500
commit96093e3cf79c0e809e13b02d12e0705f7acfdf31 (patch)
tree223d2ecbb1809580a3932b068d0c3292c12d1292 /railties/test
parent914a45b5fef39c436322bca02566d0d11e1cbb84 (diff)
downloadrails-96093e3cf79c0e809e13b02d12e0705f7acfdf31.tar.gz
rails-96093e3cf79c0e809e13b02d12e0705f7acfdf31.tar.bz2
rails-96093e3cf79c0e809e13b02d12e0705f7acfdf31.zip
Ensure Action Cable files are removed when `skip_action_cable` is set.
The Action Cable generators creates four files which need to be removed if `skip_action_cable` is set. 1. `app/assets/javascripts/cable.coffee` 2. `app/channels/application_cable/channel.rb` 3. `app/channels/application_cable/connection.rb` 4. `config/redis/cable.yml` Fixes #22669.
Diffstat (limited to 'railties/test')
-rw-r--r--railties/test/generators/app_generator_test.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/railties/test/generators/app_generator_test.rb b/railties/test/generators/app_generator_test.rb
index ddbcd4c394..66997c5f5e 100644
--- a/railties/test/generators/app_generator_test.rb
+++ b/railties/test/generators/app_generator_test.rb
@@ -379,6 +379,9 @@ class AppGeneratorTest < Rails::Generators::TestCase
def test_generator_if_skip_action_cable_is_given
run_generator [destination_root, "--skip-action-cable"]
assert_file "config/application.rb", /#\s+require\s+["']action_cable\/engine["']/
+ assert_no_file "config/redis/cable.yml"
+ assert_no_file "app/assets/javascripts/cable.coffee"
+ assert_no_file "app/channels"
end
def test_inclusion_of_javascript_runtime