aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--activesupport/lib/active_support/testing/default.rb3
-rw-r--r--activesupport/test/test_test.rb6
2 files changed, 8 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/testing/default.rb b/activesupport/lib/active_support/testing/default.rb
index 0cb0eea7d2..d97a610c79 100644
--- a/activesupport/lib/active_support/testing/default.rb
+++ b/activesupport/lib/active_support/testing/default.rb
@@ -2,7 +2,8 @@ module ActiveSupport
module Testing
module Default
def run(*args)
- return if method_name == :default_test
+ #method_name appears to be a symbol on 1.8.4 and a string on 1.8.6
+ return if @method_name.to_s == "default_test"
super
end
end
diff --git a/activesupport/test/test_test.rb b/activesupport/test/test_test.rb
index 5c8039ea1e..a05fb9b92d 100644
--- a/activesupport/test/test_test.rb
+++ b/activesupport/test/test_test.rb
@@ -63,3 +63,9 @@ class AssertDifferenceTest < Test::Unit::TestCase
def default_test; end
end
end
+
+# This should always pass
+
+class NotTestingThingsTest < Test::Unit::TestCase
+ include ActiveSupport::Testing::Default
+end