Class: FactoryGirl::Evaluation

Inherits:
Object
  • Object
show all
Includes:
Observable
Defined in:
lib/factory_girl/evaluation.rb

Instance Method Summary collapse

Constructor Details

#initialize(attribute_assigner, to_create) ⇒ Evaluation

Returns a new instance of Evaluation.



7
8
9
10
# File 'lib/factory_girl/evaluation.rb', line 7

def initialize(attribute_assigner, to_create)
  @attribute_assigner = attribute_assigner
  @to_create = to_create
end

Instance Method Details

#create(result_instance) ⇒ Object



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

def create(result_instance)
  @to_create[result_instance]
end

#notify(name, result_instance) ⇒ Object



18
19
20
21
# File 'lib/factory_girl/evaluation.rb', line 18

def notify(name, result_instance)
  changed
  notify_observers(name, result_instance)
end