diff options
Diffstat (limited to 'activerecord/test/models')
-rw-r--r-- | activerecord/test/models/author.rb | 2 | ||||
-rw-r--r-- | activerecord/test/models/post.rb | 6 |
2 files changed, 1 insertions, 7 deletions
diff --git a/activerecord/test/models/author.rb b/activerecord/test/models/author.rb index ad0123cf2c..37551c8157 100644 --- a/activerecord/test/models/author.rb +++ b/activerecord/test/models/author.rb @@ -1,5 +1,5 @@ class Author < ActiveRecord::Base - has_many :posts, :accessible => true + has_many :posts has_many :posts_with_comments, :include => :comments, :class_name => "Post" has_many :posts_with_comments_sorted_by_comment_id, :include => :comments, :class_name => "Post", :order => 'comments.id' has_many :posts_sorted_by_id_limited, :class_name => "Post", :order => 'posts.id', :limit => 1 diff --git a/activerecord/test/models/post.rb b/activerecord/test/models/post.rb index e23818eb33..3adbc0ce1f 100644 --- a/activerecord/test/models/post.rb +++ b/activerecord/test/models/post.rb @@ -33,12 +33,6 @@ class Post < ActiveRecord::Base has_and_belongs_to_many :categories has_and_belongs_to_many :special_categories, :join_table => "categories_posts", :association_foreign_key => 'category_id' - belongs_to :creatable_author, :class_name => 'Author', :accessible => true - has_one :uncreatable_comment, :class_name => 'Comment', :accessible => false, :order => 'id desc' - has_one :creatable_comment, :class_name => 'Comment', :accessible => true, :order => 'id desc' - has_many :creatable_comments, :class_name => 'Comment', :accessible => true, :dependent => :destroy - has_and_belongs_to_many :creatable_categories, :class_name => 'Category', :accessible => true - has_many :taggings, :as => :taggable has_many :tags, :through => :taggings do def add_joins_and_select |