aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/test/cases/validations/with_validation_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activemodel/test/cases/validations/with_validation_test.rb')
-rw-r--r--activemodel/test/cases/validations/with_validation_test.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/activemodel/test/cases/validations/with_validation_test.rb b/activemodel/test/cases/validations/with_validation_test.rb
index c290b49a28..fae87a6188 100644
--- a/activemodel/test/cases/validations/with_validation_test.rb
+++ b/activemodel/test/cases/validations/with_validation_test.rb
@@ -13,24 +13,24 @@ class ValidatesWithTest < ActiveRecord::TestCase
ERROR_MESSAGE = "Validation error from validator"
OTHER_ERROR_MESSAGE = "Validation error from other validator"
- class ValidatorThatAddsErrors < ActiveRecord::Validator
+ class ValidatorThatAddsErrors < ActiveModel::Validator
def validate()
record.errors[:base] << ERROR_MESSAGE
end
end
- class OtherValidatorThatAddsErrors < ActiveRecord::Validator
+ class OtherValidatorThatAddsErrors < ActiveModel::Validator
def validate()
record.errors[:base] << OTHER_ERROR_MESSAGE
end
end
- class ValidatorThatDoesNotAddErrors < ActiveRecord::Validator
+ class ValidatorThatDoesNotAddErrors < ActiveModel::Validator
def validate()
end
end
- class ValidatorThatValidatesOptions < ActiveRecord::Validator
+ class ValidatorThatValidatesOptions < ActiveModel::Validator
def validate()
if options[:field] == :first_name
record.errors[:base] << ERROR_MESSAGE