aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/models/author.rb
diff options
context:
space:
mode:
authorHongli Lai (Phusion) <hongli@phusion.nl>2008-09-04 23:01:40 +0200
committerHongli Lai (Phusion) <hongli@phusion.nl>2008-09-04 23:01:40 +0200
commitc480c1db1f302ab28a255c5423326e51d27ec5ed (patch)
treeac2afe4deb5ea436d53e421c14650bc627480f45 /activerecord/test/models/author.rb
parent08704c442d15b16511214731dd94108b737ef407 (diff)
parentd7bd01f543d18e37f9c353d847bda3456bc337c3 (diff)
downloadrails-c480c1db1f302ab28a255c5423326e51d27ec5ed.tar.gz
rails-c480c1db1f302ab28a255c5423326e51d27ec5ed.tar.bz2
rails-c480c1db1f302ab28a255c5423326e51d27ec5ed.zip
Merge branch 'master' of git@github.com:lifo/docrails
Diffstat (limited to 'activerecord/test/models/author.rb')
-rw-r--r--activerecord/test/models/author.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/activerecord/test/models/author.rb b/activerecord/test/models/author.rb
index 136dc39cf3..c6aa0293c2 100644
--- a/activerecord/test/models/author.rb
+++ b/activerecord/test/models/author.rb
@@ -32,6 +32,9 @@ class Author < ActiveRecord::Base
has_many :special_posts
has_many :special_post_comments, :through => :special_posts, :source => :comments
+ has_many :sti_posts, :class_name => 'StiPost'
+ has_many :sti_post_comments, :through => :sti_posts, :source => :comments
+
has_many :special_nonexistant_posts, :class_name => "SpecialPost", :conditions => "posts.body = 'nonexistant'"
has_many :special_nonexistant_post_comments, :through => :special_nonexistant_posts, :source => :comments, :conditions => "comments.post_id = 0"
has_many :nonexistant_comments, :through => :posts