Class: Factory::Attribute::Association
- Inherits:
-
Factory::Attribute
- Object
- Factory::Attribute
- Factory::Attribute::Association
- Defined in:
- lib/factory_girl/attribute/association.rb
Overview
:nodoc:
Instance Attribute Summary
Attributes inherited from Factory::Attribute
Instance Method Summary collapse
- #add_to(proxy) ⇒ Object
-
#initialize(name, factory, overrides) ⇒ Association
constructor
A new instance of Association.
Constructor Details
#initialize(name, factory, overrides) ⇒ Association
Returns a new instance of Association.
6 7 8 9 10 |
# File 'lib/factory_girl/attribute/association.rb', line 6 def initialize(name, factory, overrides) super(name) @factory = factory @overrides = overrides end |
Instance Method Details
#add_to(proxy) ⇒ Object
12 13 14 |
# File 'lib/factory_girl/attribute/association.rb', line 12 def add_to(proxy) proxy.associate(name, @factory, @overrides) end |