1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Merge pull request #7470 from kennyj/fix_method_redefined_warning

Fix method redefined warnings.
This commit is contained in:
Rafael Mendonça França 2012-08-28 10:40:29 -07:00
commit 844e944465
2 changed files with 6 additions and 0 deletions

View file

@ -78,6 +78,9 @@ class ExclusionValidationTest < ActiveModel::TestCase
assert p.invalid?
assert_equal ["is reserved"], p.errors[:karma]
p = Person.new
p.karma = "abe"
def p.reserved_karmas
%w()
end

View file

@ -110,6 +110,9 @@ class InclusionValidationTest < ActiveModel::TestCase
assert p.invalid?
assert_equal ["is not included in the list"], p.errors[:karma]
p = Person.new
p.karma = "Lifo"
def p.available_karmas
%w(Lifo)
end