diff options
author | Matthew Draper <matthew@trebex.net> | 2015-03-06 23:02:49 +1030 |
---|---|---|
committer | Matthew Draper <matthew@trebex.net> | 2015-03-06 23:02:49 +1030 |
commit | c96cb66351267607d8a343575ab6dded0c41dfb5 (patch) | |
tree | a54d26427d1ab9b63c5de57b00b00496bcf02f84 | |
parent | deed34d8bd2712f680055f398d9f2d22bf710115 (diff) | |
parent | e46202139647b458b8c3d5eb3a0dff29474159d3 (diff) | |
download | rails-c96cb66351267607d8a343575ab6dded0c41dfb5.tar.gz rails-c96cb66351267607d8a343575ab6dded0c41dfb5.tar.bz2 rails-c96cb66351267607d8a343575ab6dded0c41dfb5.zip |
Merge pull request #19221 from matthewd/random-tests
Run all our tests in random order
-rw-r--r-- | actionmailer/test/abstract_unit.rb | 5 | ||||
-rw-r--r-- | actionpack/Rakefile | 5 | ||||
-rw-r--r-- | actionview/Rakefile | 2 | ||||
-rw-r--r-- | actionview/test/abstract_unit.rb | 5 | ||||
-rw-r--r-- | activemodel/Rakefile | 2 | ||||
-rw-r--r-- | activemodel/test/cases/helper.rb | 5 | ||||
-rw-r--r-- | activerecord/Rakefile | 2 | ||||
-rw-r--r-- | activerecord/test/cases/helper.rb | 5 | ||||
-rw-r--r-- | activesupport/test/abstract_unit.rb | 5 | ||||
-rw-r--r-- | railties/test/abstract_unit.rb | 5 |
10 files changed, 4 insertions, 37 deletions
diff --git a/actionmailer/test/abstract_unit.rb b/actionmailer/test/abstract_unit.rb index c4d5cb8c33..ae91903c95 100644 --- a/actionmailer/test/abstract_unit.rb +++ b/actionmailer/test/abstract_unit.rb @@ -42,8 +42,3 @@ def jruby_skip(message = '') end require 'mocha/setup' # FIXME: stop using mocha - -# FIXME: we have tests that depend on run order, we should fix that and -# remove this method call. -require 'active_support/test_case' -ActiveSupport::TestCase.test_order = :sorted diff --git a/actionpack/Rakefile b/actionpack/Rakefile index 4b60b77759..3bd27f8d64 100644 --- a/actionpack/Rakefile +++ b/actionpack/Rakefile @@ -9,10 +9,7 @@ task :default => :test # Run the unit tests Rake::TestTask.new 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 = test_files.sort + t.test_files = test_files t.warning = true t.verbose = true diff --git a/actionview/Rakefile b/actionview/Rakefile index 1b71435948..2b752b83df 100644 --- a/actionview/Rakefile +++ b/actionview/Rakefile @@ -18,7 +18,7 @@ namespace :test do Rake::TestTask.new(:template) do |t| t.libs << 'test' - t.test_files = Dir.glob('test/template/**/*_test.rb').sort + t.test_files = Dir.glob('test/template/**/*_test.rb') t.warning = true t.verbose = true t.ruby_opts = ["--dev"] if defined?(JRUBY_VERSION) diff --git a/actionview/test/abstract_unit.rb b/actionview/test/abstract_unit.rb index fc1ca9efdf..3eded74f1b 100644 --- a/actionview/test/abstract_unit.rb +++ b/actionview/test/abstract_unit.rb @@ -338,8 +338,3 @@ def jruby_skip(message = '') end require 'mocha/setup' # FIXME: stop using mocha - -# FIXME: we have tests that depend on run order, we should fix that and -# remove this method call. -require 'active_support/test_case' -ActiveSupport::TestCase.test_order = :sorted diff --git a/activemodel/Rakefile b/activemodel/Rakefile index c30a559ef5..7256285a41 100644 --- a/activemodel/Rakefile +++ b/activemodel/Rakefile @@ -6,7 +6,7 @@ task :default => :test Rake::TestTask.new do |t| t.libs << "test" - t.test_files = Dir.glob("#{dir}/test/cases/**/*_test.rb").sort + t.test_files = Dir.glob("#{dir}/test/cases/**/*_test.rb") t.warning = true t.verbose = true t.ruby_opts = ["--dev"] if defined?(JRUBY_VERSION) diff --git a/activemodel/test/cases/helper.rb b/activemodel/test/cases/helper.rb index 3276f69f09..2b9de5e5d2 100644 --- a/activemodel/test/cases/helper.rb +++ b/activemodel/test/cases/helper.rb @@ -22,8 +22,3 @@ end def jruby_skip(message = '') skip message if defined?(JRUBY_VERSION) end - -# FIXME: we have tests that depend on run order, we should fix that and -# remove this method call. -require 'active_support/test_case' -ActiveSupport::TestCase.test_order = :sorted diff --git a/activerecord/Rakefile b/activerecord/Rakefile index 976b559da9..f1facac21b 100644 --- a/activerecord/Rakefile +++ b/activerecord/Rakefile @@ -51,7 +51,7 @@ end t.libs << 'test' t.test_files = (Dir.glob( "test/cases/**/*_test.rb" ).reject { |x| x =~ /\/adapters\// - } + Dir.glob("test/cases/adapters/#{adapter_short}/**/*_test.rb")).sort + } + Dir.glob("test/cases/adapters/#{adapter_short}/**/*_test.rb")) t.warning = true t.verbose = true diff --git a/activerecord/test/cases/helper.rb b/activerecord/test/cases/helper.rb index f2ba28a32f..b118ecc125 100644 --- a/activerecord/test/cases/helper.rb +++ b/activerecord/test/cases/helper.rb @@ -203,8 +203,3 @@ module InTimeZone end require 'mocha/setup' # FIXME: stop using mocha - -# FIXME: we have tests that depend on run order, we should fix that and -# remove this method call. -require 'active_support/test_case' -ActiveSupport::TestCase.test_order = :sorted diff --git a/activesupport/test/abstract_unit.rb b/activesupport/test/abstract_unit.rb index f65ec962f9..7ffcae6007 100644 --- a/activesupport/test/abstract_unit.rb +++ b/activesupport/test/abstract_unit.rb @@ -38,8 +38,3 @@ def jruby_skip(message = '') end require 'mocha/setup' # FIXME: stop using mocha - -# FIXME: we have tests that depend on run order, we should fix that and -# remove this method call. -require 'active_support/test_case' -ActiveSupport::TestCase.test_order = :sorted diff --git a/railties/test/abstract_unit.rb b/railties/test/abstract_unit.rb index ab8883e135..794d180e5d 100644 --- a/railties/test/abstract_unit.rb +++ b/railties/test/abstract_unit.rb @@ -30,9 +30,4 @@ end class ActiveSupport::TestCase include ActiveSupport::Testing::Stream - - # FIXME: we have tests that depend on run order, we should fix that and - # remove this method call. - self.test_order = :sorted - end |