diff options
author | Yuki Nishijima <mail@yukinishijima.net> | 2014-09-21 11:34:37 -0700 |
---|---|---|
committer | Yuki Nishijima <mail@yukinishijima.net> | 2014-09-21 11:34:37 -0700 |
commit | 0756375fb408a7e07acf3fea691e04530e61870a (patch) | |
tree | 44293f8bf1e0c48fd7a07b3677eefeefa3b19bd8 /activerecord/test/cases | |
parent | cdbb20618669055c6bbed6c414e467e579681231 (diff) | |
download | rails-0756375fb408a7e07acf3fea691e04530e61870a.tar.gz rails-0756375fb408a7e07acf3fea691e04530e61870a.tar.bz2 rails-0756375fb408a7e07acf3fea691e04530e61870a.zip |
Fix assertions in AR::TestCase::AttributeMethodsTest
This test has always been green because it uses "assert" and the first
argument is an truthy class/object.
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r-- | activerecord/test/cases/attribute_methods_test.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/activerecord/test/cases/attribute_methods_test.rb b/activerecord/test/cases/attribute_methods_test.rb index b42cc3a173..7ca7349528 100644 --- a/activerecord/test/cases/attribute_methods_test.rb +++ b/activerecord/test/cases/attribute_methods_test.rb @@ -738,9 +738,9 @@ class AttributeMethodsTest < ActiveRecord::TestCase error = assert_raises(ActiveRecord::UnknownAttributeError) { @target.new(:hello => "world") } - assert @target, error.record - assert "hello", error.attribute - assert "unknown attribute: hello", error.message + assert_instance_of @target, error.record + assert_equal "hello", error.attribute + assert_equal "unknown attribute: hello", error.message end def test_methods_override_in_multi_level_subclass |