diff options
author | Rafael França <rafaelmfranca@gmail.com> | 2017-11-06 22:48:02 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-06 22:48:02 -0500 |
commit | 2e585e4040854ab561465a2cce32a488355fe307 (patch) | |
tree | 890462ecb0ec164e12abc5184c6567f5ffff287f /activemodel/test/models | |
parent | 212481b490bcd5db77aae1a0a338e25eedc98471 (diff) | |
parent | 3ff2c158372bce45ea46bd3b49c49022a4259aba (diff) | |
download | rails-2e585e4040854ab561465a2cce32a488355fe307.tar.gz rails-2e585e4040854ab561465a2cce32a488355fe307.tar.bz2 rails-2e585e4040854ab561465a2cce32a488355fe307.zip |
Merge pull request #31061 from bogdanvlviv/test-if-unless-options-for-validations
Add cases to test combining validation conditions
Diffstat (limited to 'activemodel/test/models')
-rw-r--r-- | activemodel/test/models/person.rb | 4 | ||||
-rw-r--r-- | activemodel/test/models/topic.rb | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/activemodel/test/models/person.rb b/activemodel/test/models/person.rb index b61fdf76b1..8dd8ceadad 100644 --- a/activemodel/test/models/person.rb +++ b/activemodel/test/models/person.rb @@ -9,6 +9,10 @@ class Person def condition_is_true true end + + def condition_is_false + false + end end class Person::Gender diff --git a/activemodel/test/models/topic.rb b/activemodel/test/models/topic.rb index 2f4e92c3b2..b0af00ee45 100644 --- a/activemodel/test/models/topic.rb +++ b/activemodel/test/models/topic.rb @@ -23,7 +23,7 @@ class Topic true end - def condition_is_true_but_its_not + def condition_is_false false end |