Class: CabezaDeTermo::JsonSpec::ExpectingAnyOfExpectationDefinition

Inherits:
ExpectationDefinition show all
Defined in:
lib/cabeza-de-termo/json-spec/expectations-library/definition-builders/expectation-builders/expecting-any-of-expectation-definition.rb

Instance Method Summary collapse

Methods inherited from ExpectationDefinition

#modifier_instantiator

Constructor Details

#initialize(*args) ⇒ ExpectingAnyOfExpectationDefinition

Returns a new instance of ExpectingAnyOfExpectationDefinition.



8
9
10
11
12
# File 'lib/cabeza-de-termo/json-spec/expectations-library/definition-builders/expectation-builders/expecting-any-of-expectation-definition.rb', line 8

def initialize(*args)
	super(*args)

	@expectation_instantiatiors = []
end

Instance Method Details

#expectation_instantiatorObject



18
19
20
# File 'lib/cabeza-de-termo/json-spec/expectations-library/definition-builders/expectation-builders/expecting-any-of-expectation-definition.rb', line 18

def expectation_instantiator()
	AnyExpectationCompositeInstantiator.with_all(@expectation_instantiatiors)
end

#or_also(expectation_method, *args) ⇒ Object



14
15
16
# File 'lib/cabeza-de-termo/json-spec/expectations-library/definition-builders/expectation-builders/expecting-any-of-expectation-definition.rb', line 14

def or_also(expectation_method, *args)
	@expectation_instantiatiors << PartialApplicationInstantiator.new(expectation_instantiator_for(expectation_method), args)
end