Class: FactoryGirl::Attribute::Implicit

Inherits:
FactoryGirl::Attribute show all
Defined in:
lib/factory_girl/attribute/implicit.rb

Instance Attribute Summary

Attributes inherited from FactoryGirl::Attribute

#ignored, #name

Instance Method Summary collapse

Methods inherited from FactoryGirl::Attribute

#<=>, #aliases_for?, #ignore, #priority

Constructor Details

#initialize(name, factory = nil) ⇒ Implicit

Returns a new instance of Implicit.



5
6
7
8
# File 'lib/factory_girl/attribute/implicit.rb', line 5

def initialize(name, factory = nil)
  super(name)
  @factory = factory
end

Instance Method Details

#add_to(proxy) ⇒ Object



10
11
12
# File 'lib/factory_girl/attribute/implicit.rb', line 10

def add_to(proxy)
  implementation.add_to(proxy)
end

#association?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'lib/factory_girl/attribute/implicit.rb', line 14

def association?
  implementation.association?
end

#factoryObject



18
19
20
# File 'lib/factory_girl/attribute/implicit.rb', line 18

def factory
  name
end