mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
All tests should be ran under isolated_test too
This commit is contained in:
parent
d5cfc72f55
commit
762d761673
1 changed files with 5 additions and 5 deletions
|
@ -34,22 +34,22 @@ end
|
|||
desc "Run all unit tests"
|
||||
task :test => [:test_action_pack, :test_active_record_integration]
|
||||
|
||||
TESTS_GLOB = "test/{abstract,controller,dispatch,new_base,template,html-scanner}/**/*_test.rb"
|
||||
|
||||
Rake::TestTask.new(:test_action_pack) do |t|
|
||||
t.libs << 'test'
|
||||
|
||||
# make sure we include the tests in alphabetical order as on some systems
|
||||
# this will not happen automatically and the tests (as a whole) will error
|
||||
t.test_files = Dir.glob( "test/{abstract,controller,dispatch,new_base,template,html-scanner}/**/*_test.rb" ).sort
|
||||
t.test_files = Dir.glob(TESTS_GLOB).sort
|
||||
|
||||
t.verbose = true
|
||||
#t.warning = true
|
||||
# t.warning = true
|
||||
end
|
||||
|
||||
task :isolated_test do
|
||||
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
|
||||
Dir.glob("test/{controller,dispatch,template}/**/*_test.rb").all? do |file|
|
||||
system(ruby, "-Itest", file)
|
||||
end or raise "Failures"
|
||||
Dir.glob(TESTS_GLOB).all? { |file| system(ruby, '-Ilib:test', file) } or raise "Failures"
|
||||
end
|
||||
|
||||
desc 'ActiveRecord Integration Tests'
|
||||
|
|
Loading…
Reference in a new issue