diff options
author | José Valim <jose.valim@gmail.com> | 2011-07-07 03:59:01 -0700 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2011-07-07 03:59:01 -0700 |
commit | 03a016c08fae67a1fa2759cf98eabb4a5d59e23c (patch) | |
tree | 2ed5d9c040159efabd8cd1834c4604b8c8118838 | |
parent | 1bad08f1168709a657110281f9a9e17c514eda92 (diff) | |
parent | e722fbb50f5d95fd5d5c3451f7fbf6f71b561683 (diff) | |
download | rails-03a016c08fae67a1fa2759cf98eabb4a5d59e23c.tar.gz rails-03a016c08fae67a1fa2759cf98eabb4a5d59e23c.tar.bz2 rails-03a016c08fae67a1fa2759cf98eabb4a5d59e23c.zip |
Merge pull request #1406 from dmathieu/fix_test_warnings
Fix test warnings
-rw-r--r-- | activesupport/test/whiny_nil_test.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/activesupport/test/whiny_nil_test.rb b/activesupport/test/whiny_nil_test.rb index ec3ca99ee6..1acaf7228f 100644 --- a/activesupport/test/whiny_nil_test.rb +++ b/activesupport/test/whiny_nil_test.rb @@ -33,11 +33,10 @@ class WhinyNilTest < Test::Unit::TestCase 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 |