Displaying 2 results from an estimated 2 matches for "include_association".
Did you mean:
include_associations
2009 Jan 21
3
Nested serialization with to_json and to_xml with array and hash element
Title: Nested serialization with to_json and to_xml with array and
hash element
class Person < ActiveRecord::Base
has_one :address
has_one :job
def office()
return "Executive_Suite"
end
end
class Address < ActiveRecord::Base
belongs_to :person
end
class Job < ActiveRecord::Base
belongs_to :person
has_one :paygrade
def Title
return "Engineer"
end
end
2010 Sep 08
4
Re-using Rspec Matchers
Hey Everyone,
Is it good practice to call matchers from within matchers? Kinda like this pattern:
See: http://gist.github.com/570467
--
Brian