aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/generators/actions_test.rb
diff options
context:
space:
mode:
authorMohit Natoo <mohitnatoo@gmail.com>2016-02-29 18:56:02 +0530
committerMohit Natoo <mohitnatoo@gmail.com>2016-02-29 19:12:18 +0530
commit60d2322ad795869025570c44a553184dc047a2fc (patch)
tree38d2634d0ed452d8099dff660fd5a0d472df9d07 /railties/test/generators/actions_test.rb
parent259032e20ae77d2de4b450396b9662f3e9852125 (diff)
downloadrails-60d2322ad795869025570c44a553184dc047a2fc.tar.gz
rails-60d2322ad795869025570c44a553184dc047a2fc.tar.bz2
rails-60d2322ad795869025570c44a553184dc047a2fc.zip
- Made changes to have test cases in actions_test more readable.
Changed description with tests related to rails_command.
Diffstat (limited to 'railties/test/generators/actions_test.rb')
-rw-r--r--railties/test/generators/actions_test.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/railties/test/generators/actions_test.rb b/railties/test/generators/actions_test.rb
index e44e5ce963..58394a11f0 100644
--- a/railties/test/generators/actions_test.rb
+++ b/railties/test/generators/actions_test.rb
@@ -215,7 +215,7 @@ class ActionsTest < Rails::Generators::TestCase
end
end
- test "rails with RAILS_ENV variable should run rake command in env" do
+ test "rails command with RAILS_ENV variable should run rake command in env" do
assert_called_with(generator, :run, ['rails log:clear RAILS_ENV=production', verbose: false]) do
with_rails_env "production" do
action :rake, 'log:clear'
@@ -231,7 +231,7 @@ class ActionsTest < Rails::Generators::TestCase
end
end
- def test_rails_with_sudo_option_should_run_rake_command_with_sudo
+ test "rails command with sudo option should run rake command with sudo" do
assert_called_with(generator, :run, ["sudo rails log:clear RAILS_ENV=development", verbose: false]) do
with_rails_env nil do
action :rake, 'log:clear', sudo: true
@@ -239,7 +239,7 @@ class ActionsTest < Rails::Generators::TestCase
end
end
- def test_rails_command_should_run_rails_command_with_default_env
+ test "rails command should run rails_command with default env" do
assert_called_with(generator, :run, ["rails log:clear RAILS_ENV=development", verbose: false]) do
with_rails_env nil do
action :rails_command, 'log:clear'
@@ -247,13 +247,13 @@ class ActionsTest < Rails::Generators::TestCase
end
end
- def test_rails_command_with_env_option_should_run_rails_command_in_env
+ test "rails command with env option should run rails_command with same env" do
assert_called_with(generator, :run, ['rails log:clear RAILS_ENV=production', verbose: false]) do
action :rails_command, 'log:clear', env: 'production'
end
end
- def test_rails_command_with_rails_env_variable_should_run_rails_command_in_env
+ test "rails command with RAILS_ENV variable should run rails_command in env" do
assert_called_with(generator, :run, ['rails log:clear RAILS_ENV=production', verbose: false]) do
with_rails_env "production" do
action :rails_command, 'log:clear'
@@ -269,7 +269,7 @@ class ActionsTest < Rails::Generators::TestCase
end
end
- def test_rails_command_with_sudo_option_should_run_rails_command_with_sudo
+ test "rails command with sudo option should run rails_command with sudo" do
assert_called_with(generator, :run, ["sudo rails log:clear RAILS_ENV=development", verbose: false]) do
with_rails_env nil do
action :rails_command, 'log:clear', sudo: true