aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test/application/rake_test.rb
diff options
context:
space:
mode:
authorMike Moore <mike@blowmage.com>2012-10-07 22:59:42 -0600
committerMike Moore <mike@blowmage.com>2012-10-09 17:53:56 -0600
commit2a68f68aead9fd65ecac8062ca8efc15f5bab418 (patch)
tree632bf64b5a6974c2e47d5300ff8d15a143133af5 /railties/test/application/rake_test.rb
parent0787cea3bb5e6f2c216e71090732bc55ee03c7dc (diff)
downloadrails-2a68f68aead9fd65ecac8062ca8efc15f5bab418.tar.gz
rails-2a68f68aead9fd65ecac8062ca8efc15f5bab418.tar.bz2
rails-2a68f68aead9fd65ecac8062ca8efc15f5bab418.zip
Update test locations
Change the default test locations to avoid confusion around the common testing terms "unit" and "functional". Add new rake tasks for the new locations, while maintaining backwards compatibility with the old rake tasks. New testing locations are as follows: app/models -> test/models (was test/units) app/helpers -> test/helpers (was test/units/helpers) app/controllers -> test/controllers (was test/functional) app/mailers -> test/mailers (was test/functional)
Diffstat (limited to 'railties/test/application/rake_test.rb')
-rw-r--r--railties/test/application/rake_test.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/railties/test/application/rake_test.rb b/railties/test/application/rake_test.rb
index b05fe3aed5..2e7426150c 100644
--- a/railties/test/application/rake_test.rb
+++ b/railties/test/application/rake_test.rb
@@ -86,12 +86,12 @@ module ApplicationTests
def test_rake_test_error_output
Dir.chdir(app_path){ `rake db:migrate` }
- app_file "test/unit/one_unit_test.rb", <<-RUBY
- raise 'unit'
+ app_file "test/models/one_model_test.rb", <<-RUBY
+ raise 'models'
RUBY
- app_file "test/functional/one_functional_test.rb", <<-RUBY
- raise 'functional'
+ app_file "test/controllers/one_controller_test.rb", <<-RUBY
+ raise 'controllers'
RUBY
app_file "test/integration/one_integration_test.rb", <<-RUBY
@@ -100,8 +100,8 @@ module ApplicationTests
silence_stderr do
output = Dir.chdir(app_path) { `rake test 2>&1` }
- assert_match 'unit', output
- assert_match 'functional', output
+ assert_match 'models', output
+ assert_match 'controllers', output
assert_match 'integration', output
end
end