diff options
Diffstat (limited to 'activesupport/test')
-rw-r--r-- | activesupport/test/whiny_nil_test.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/activesupport/test/whiny_nil_test.rb b/activesupport/test/whiny_nil_test.rb index a3bedd7c14..9ed31bfef5 100644 --- a/activesupport/test/whiny_nil_test.rb +++ b/activesupport/test/whiny_nil_test.rb @@ -15,19 +15,21 @@ class WhinyNilTest < Test::Unit::TestCase def test_unchanged nil.method_thats_not_in_whiners rescue NoMethodError => nme - assert_match(/nil:NilClass/, nme.message) + assert_match(/nil.method_thats_not_in_whiners/, nme.message) end def test_active_record nil.save! rescue NoMethodError => nme assert(!(nme.message =~ /nil:NilClass/)) + assert_match(/nil\.save!/, nme.message) end def test_array nil.each rescue NoMethodError => nme assert(!(nme.message =~ /nil:NilClass/)) + assert_match(/nil\.each/, nme.message) end def test_id |