Namespace
Methods
A
C
F
G
L
N
R
T
W
Included Modules
Attributes
[RW] author
[RW] comment_ids
[RW] comments
[RW] tags
Class Public methods
log(message=nil, side=nil, new_record=nil)
# File activerecord/test/models/post.rb, line 171
def self.log(message=nil, side=nil, new_record=nil)
  return @log if message.nil?
  @log << [message, side, new_record]
end
new(*args)
# File actionpack/test/lib/controller/fake_models.rb, line 39
def initialize(*args)
  super
  @persisted = false
end
reset_log()
# File activerecord/test/models/post.rb, line 167
def self.reset_log
  @log = []
end
top(limit)
# File activerecord/test/models/post.rb, line 159
def self.top(limit)
  ranked_by_comments.limit_by(limit)
end
written_by(author)
# File activerecord/test/models/post.rb, line 163
def self.written_by(author)
  where(id: author.posts.pluck(:id))
end
Instance Public methods
add_joins_and_select()
# File activerecord/test/models/post.rb, line 95
def add_joins_and_select
  select('tags.*, authors.id as author_id')
    .joins('left outer join posts on taggings.taggable_id = posts.id left outer join authors on posts.author_id = authors.id')
    .to_a
end
author_attributes=(attributes)
# File actionpack/test/lib/controller/fake_models.rb, line 45
def author_attributes=(attributes); end
comments_attributes=(attributes)
# File actionpack/test/lib/controller/fake_models.rb, line 48
def comments_attributes=(attributes); end
find_most_recent()
# File activerecord/test/models/post.rb, line 47
def find_most_recent
  order("id DESC").first
end
first_comment()
# File activerecord/test/models/post.rb, line 30
def first_comment
  super.body
end
greeting()
# File activerecord/test/models/post.rb, line 61
def greeting
  "hello"
end
newest()
# File activerecord/test/models/post.rb, line 51
def newest
  created.last
end
tags_attributes=(attributes)
# File actionpack/test/lib/controller/fake_models.rb, line 51
def tags_attributes=(attributes); end
the_association()
# File activerecord/test/models/post.rb, line 55
def the_association
  proxy_association
end