diff options
-rw-r--r-- | actionmailer/test/abstract_unit.rb | 2 | ||||
-rw-r--r-- | actionpack/test/abstract_unit.rb | 2 | ||||
-rw-r--r-- | actionview/test/abstract_unit.rb | 2 | ||||
-rw-r--r-- | activemodel/test/cases/helper.rb | 2 | ||||
-rw-r--r-- | activerecord/test/cases/helper.rb | 2 | ||||
-rw-r--r-- | activesupport/CHANGELOG.md | 2 | ||||
-rw-r--r-- | activesupport/lib/active_support/test_case.rb | 4 | ||||
-rw-r--r-- | activesupport/test/abstract_unit.rb | 2 | ||||
-rw-r--r-- | railties/test/abstract_unit.rb | 2 |
9 files changed, 12 insertions, 8 deletions
diff --git a/actionmailer/test/abstract_unit.rb b/actionmailer/test/abstract_unit.rb index b07d8c7087..1281b1bcfc 100644 --- a/actionmailer/test/abstract_unit.rb +++ b/actionmailer/test/abstract_unit.rb @@ -55,4 +55,4 @@ 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.i_suck_and_my_tests_are_order_dependent! +ActiveSupport::TestCase.my_tests_are_order_dependent! diff --git a/actionpack/test/abstract_unit.rb b/actionpack/test/abstract_unit.rb index 08f8f64123..376add06ca 100644 --- a/actionpack/test/abstract_unit.rb +++ b/actionpack/test/abstract_unit.rb @@ -501,4 +501,4 @@ 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.i_suck_and_my_tests_are_order_dependent! +ActiveSupport::TestCase.my_tests_are_order_dependent! diff --git a/actionview/test/abstract_unit.rb b/actionview/test/abstract_unit.rb index 4cc4cd2d3e..923e637f11 100644 --- a/actionview/test/abstract_unit.rb +++ b/actionview/test/abstract_unit.rb @@ -344,4 +344,4 @@ 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.i_suck_and_my_tests_are_order_dependent! +ActiveSupport::TestCase.my_tests_are_order_dependent! diff --git a/activemodel/test/cases/helper.rb b/activemodel/test/cases/helper.rb index 75cf90d7cd..5e80353836 100644 --- a/activemodel/test/cases/helper.rb +++ b/activemodel/test/cases/helper.rb @@ -17,4 +17,4 @@ 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.i_suck_and_my_tests_are_order_dependent! +ActiveSupport::TestCase.my_tests_are_order_dependent! diff --git a/activerecord/test/cases/helper.rb b/activerecord/test/cases/helper.rb index 9aa1281e9d..ff81855ef3 100644 --- a/activerecord/test/cases/helper.rb +++ b/activerecord/test/cases/helper.rb @@ -205,4 +205,4 @@ 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.i_suck_and_my_tests_are_order_dependent! +ActiveSupport::TestCase.tests_are_order_dependent! diff --git a/activesupport/CHANGELOG.md b/activesupport/CHANGELOG.md index 4ee70ebd30..b961b373cb 100644 --- a/activesupport/CHANGELOG.md +++ b/activesupport/CHANGELOG.md @@ -1,6 +1,6 @@ * Fix ActiveSupport::TestCase not to order users' test cases by default. If this change breaks your tests because your tests are order dependent, you need to explicitly call - ActiveSupport::TestCase.i_suck_and_my_tests_are_order_dependent! at the top of your tests. + ActiveSupport::TestCase.my_tests_are_order_dependent! at the top of your tests. *Akira Matsuda* diff --git a/activesupport/lib/active_support/test_case.rb b/activesupport/lib/active_support/test_case.rb index 154c8e5d14..0df599b692 100644 --- a/activesupport/lib/active_support/test_case.rb +++ b/activesupport/lib/active_support/test_case.rb @@ -15,6 +15,10 @@ module ActiveSupport class TestCase < ::Minitest::Test Assertion = Minitest::Assertion + class << self + alias :my_tests_are_order_dependent! :i_suck_and_my_tests_are_order_dependent! + end + alias_method :method_name, :name include ActiveSupport::Testing::TaggedLogging diff --git a/activesupport/test/abstract_unit.rb b/activesupport/test/abstract_unit.rb index e29a248aa0..52fbaf8a85 100644 --- a/activesupport/test/abstract_unit.rb +++ b/activesupport/test/abstract_unit.rb @@ -42,4 +42,4 @@ 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.i_suck_and_my_tests_are_order_dependent! +ActiveSupport::TestCase.my_tests_are_order_dependent! diff --git a/railties/test/abstract_unit.rb b/railties/test/abstract_unit.rb index 1b0b9f3aa5..d8800eaa0f 100644 --- a/railties/test/abstract_unit.rb +++ b/railties/test/abstract_unit.rb @@ -30,7 +30,7 @@ end class ActiveSupport::TestCase # FIXME: we have tests that depend on run order, we should fix that and # remove this method call. - self.i_suck_and_my_tests_are_order_dependent! + self.my_tests_are_order_dependent! private |