Skip to content

Commit

Permalink
Revert "Validators should at model level and not at AR:Base level [Cl…
Browse files Browse the repository at this point in the history
…oses #4804]"

This reverts commit e11bb95.
  • Loading branch information
wycats committed Jun 13, 2010
1 parent f28d5cf commit d675493
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions activerecord/test/cases/validations_test.rb
Expand Up @@ -9,8 +9,6 @@
require 'models/owner'
require 'models/pet'
require 'models/event'
require 'models/parrot'
require 'models/company'

class ProtectedPerson < ActiveRecord::Base
set_table_name 'people'
Expand Down Expand Up @@ -191,12 +189,4 @@ def test_validate_is_deprecated_on_update
end
assert_equal ["always invalid", "invalid on update"], p.errors[:name]
end

def test_validators
assert_equal 1, Parrot.validators.size
assert_equal 1, Company.validators.size
assert_equal 1, Parrot.validators_on(:name).size
assert_equal 1, Company.validators_on(:name).size
end

end

0 comments on commit d675493

Please sign in to comment.