aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/models/person.rb
diff options
context:
space:
mode:
authorSubba Rao Pasupuleti <subbarao.pasupuleti@gmail.com>2010-07-19 21:26:57 -0400
committerJosé Valim <jose.valim@gmail.com>2010-07-21 15:01:40 +0200
commitd77c3b669ce052234868b3d8e4f066e1baf9dbd5 (patch)
tree36d1b68df14a71860ed6133c12792f65c053f784 /activerecord/test/models/person.rb
parent992711a86bc4ddd4460f9067e49eea36b37ca94f (diff)
downloadrails-d77c3b669ce052234868b3d8e4f066e1baf9dbd5.tar.gz
rails-d77c3b669ce052234868b3d8e4f066e1baf9dbd5.tar.bz2
rails-d77c3b669ce052234868b3d8e4f066e1baf9dbd5.zip
eagerly loaded association records should respect default_scope [#2931 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
Diffstat (limited to 'activerecord/test/models/person.rb')
-rw-r--r--activerecord/test/models/person.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/activerecord/test/models/person.rb b/activerecord/test/models/person.rb
index 2a73b1ee01..be7463f7c8 100644
--- a/activerecord/test/models/person.rb
+++ b/activerecord/test/models/person.rb
@@ -4,6 +4,7 @@ class Person < ActiveRecord::Base
has_many :posts_with_no_comments, :through => :readers, :source => :post, :include => :comments, :conditions => 'comments.id is null'
has_many :references
+ has_many :bad_references
has_many :jobs, :through => :references
has_one :favourite_reference, :class_name => 'Reference', :conditions => ['favourite=?', true]
has_many :posts_with_comments_sorted_by_comment_id, :through => :readers, :source => :post, :include => :comments, :order => 'comments.id'