aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/validations
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2009-12-28 14:07:23 -0800
committerJeremy Kemper <jeremy@bitsweat.net>2009-12-28 14:07:23 -0800
commit949c8c0d0e92e6e7855dc4decc10eb4c658e0ede (patch)
tree18f556845f47bb08f14e1fbb87a97217669de7c1 /activerecord/test/cases/validations
parent1b91f534ce91ff5d0a4d39d96a8f19b58022d403 (diff)
downloadrails-949c8c0d0e92e6e7855dc4decc10eb4c658e0ede.tar.gz
rails-949c8c0d0e92e6e7855dc4decc10eb4c658e0ede.tar.bz2
rails-949c8c0d0e92e6e7855dc4decc10eb4c658e0ede.zip
Don't publicize with_scope for tests since it may shadow public misuse
Diffstat (limited to 'activerecord/test/cases/validations')
-rw-r--r--activerecord/test/cases/validations/uniqueness_validation_test.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/test/cases/validations/uniqueness_validation_test.rb b/activerecord/test/cases/validations/uniqueness_validation_test.rb
index 17ba4e2f8a..db633339f3 100644
--- a/activerecord/test/cases/validations/uniqueness_validation_test.rb
+++ b/activerecord/test/cases/validations/uniqueness_validation_test.rb
@@ -213,7 +213,7 @@ class UniquenessValidationTest < ActiveRecord::TestCase
def test_validates_uniqueness_inside_with_scope
Topic.validates_uniqueness_of(:title)
- Topic.with_scope(:find => { :conditions => { :author_name => "David" } }) do
+ Topic.send(:with_scope, :find => { :conditions => { :author_name => "David" } }) do
t1 = Topic.new("title" => "I'm unique!", "author_name" => "Mary")
assert t1.save
t2 = Topic.new("title" => "I'm unique!", "author_name" => "David")