Permalink
Browse files

Merge pull request #1406 from dmathieu/fix_test_warnings

Fix test warnings
  • Loading branch information...
josevalim committed Jul 7, 2011
2 parents 1bad08f + e722fbb commit 03a016c08fae67a1fa2759cf98eabb4a5d59e23c
Showing with 1 addition and 2 deletions.
  1. +1 −2 activesupport/test/whiny_nil_test.rb
@@ -33,11 +33,10 @@ def test_array
end
def test_id
- nil.stubs(:object_id).returns(999)
nil.id
rescue RuntimeError => nme
assert_no_match(/nil:NilClass/, nme.message)
- assert_match(/999/, nme.message)
+ assert_match(Regexp.new(nil.object_id.to_s), nme.message)
end
def test_no_to_ary_coercion

0 comments on commit 03a016c

Please sign in to comment.