From e11348063b1ff0149b8392ba455a7cefcddb5f39 Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Fri, 27 Jul 2012 12:50:21 -0700 Subject: Don't test language-level exception messages Ruby implementations should be free to produce exception messages that are not identical to MRI. For example, Rubinius produces 'Expected an even number, got 5'. --- activesupport/test/ordered_hash_test.rb | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'activesupport') diff --git a/activesupport/test/ordered_hash_test.rb b/activesupport/test/ordered_hash_test.rb index e8defd396b..ac85ba1f21 100644 --- a/activesupport/test/ordered_hash_test.rb +++ b/activesupport/test/ordered_hash_test.rb @@ -226,12 +226,8 @@ class OrderedHashTest < ActiveSupport::TestCase end def test_alternate_initialization_raises_exception_on_odd_length_args - begin + assert_raises ArgumentError do ActiveSupport::OrderedHash[1,2,3,4,5] - flunk "Hash::[] should have raised an exception on initialization " + - "with an odd number of parameters" - rescue ArgumentError => e - assert_equal "odd number of arguments for Hash", e.message end end -- cgit v1.2.3