aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/test/cases
diff options
context:
space:
mode:
authorKuldeep Aggarwal <kd.engineer@yahoo.co.in>2014-06-10 12:27:17 +0530
committerKuldeep Aggarwal <kd.engineer@yahoo.co.in>2014-06-10 12:27:17 +0530
commite5cc892ce66968d4e15ea3fbf62a9fdd43b410d9 (patch)
treea1962d57d8ad1857df2f7a5d412fe61c00d7328b /activemodel/test/cases
parent254efb712ac10fd8e165fb34bb459f4abd59b213 (diff)
downloadrails-e5cc892ce66968d4e15ea3fbf62a9fdd43b410d9.tar.gz
rails-e5cc892ce66968d4e15ea3fbf62a9fdd43b410d9.tar.bz2
rails-e5cc892ce66968d4e15ea3fbf62a9fdd43b410d9.zip
remove depricated Validatior#setup
Diffstat (limited to 'activemodel/test/cases')
-rw-r--r--activemodel/test/cases/validations_test.rb21
1 files changed, 0 insertions, 21 deletions
diff --git a/activemodel/test/cases/validations_test.rb b/activemodel/test/cases/validations_test.rb
index 6a74ee353d..4fee704ef5 100644
--- a/activemodel/test/cases/validations_test.rb
+++ b/activemodel/test/cases/validations_test.rb
@@ -378,25 +378,4 @@ class ValidationsTest < ActiveModel::TestCase
assert topic.invalid?
assert duped.valid?
end
-
- # validator test:
- def test_setup_is_deprecated_but_still_receives_klass # TODO: remove me in 4.2.
- validator_class = Class.new(ActiveModel::Validator) do
- def setup(klass)
- @old_klass = klass
- end
-
- def validate(*)
- @old_klass == Topic or raise "#setup didn't work"
- end
- end
-
- assert_deprecated do
- Topic.validates_with validator_class
- end
-
- t = Topic.new
- t.valid?
- end
-
end