rails/activerecord/test/cases/validations
eileencodes 2c02bc0a47 Revert changes to validations from PR #18612
In order to fix issue #17621 we added a check to validations that
determined if a record should be validated. Based on the existing tests
and behavior we wanted we determined the best way to do that was by
checking if `!record.peristed? || record.changed? || record.marked_for_destruction?`

This change didn't make it into a release until now. When #23790 was
opened we realized that `valid?` and `invalid?` were broken and did not
work on persisted records because of the `!record.persisted?`.

While there is still a bug that #17621 brought up, this change was too
drastic and should not be a RC blocker. I will work on fixing this so
that we don't break `valid?` but also aren't validating parent records
through child records if that parent record is validate false. This
change removes the code changes to validate and the corresponding tests.
It adds tests for two of the bugs found since Rails 5 beta2 release.

Fixes #17621
2016-02-23 15:21:46 -05:00
..
absence_validation_test.rb Revert changes to validations from PR #18612 2016-02-23 15:21:46 -05:00
association_validation_test.rb Improve support for non Active Record objects on validates_associated 2015-11-08 10:58:39 -02:00
i18n_generate_message_validation_test.rb use the new clear_validators! api everywhere to reset validators in tests 2014-01-28 00:13:35 +05:30
i18n_validation_test.rb Removed mocha from Active Record Part 1 2015-08-25 22:07:25 +05:30
length_validation_test.rb Revert changes to validations from PR #18612 2016-02-23 15:21:46 -05:00
presence_validation_test.rb Revert changes to validations from PR #18612 2016-02-23 15:21:46 -05:00
uniqueness_validation_test.rb Revert changes to validations from PR #18612 2016-02-23 15:21:46 -05:00