PHP Class Eloquent\Phony\Verification\IterableVerifier

Inheritance: extends AbstractCardinalityVerifierEventCollection
Afficher le fichier Open project: eloquent/phony Class Usage Examples

Protected Properties

Свойство Type Description
$assertionRecorder
$assertionRenderer
$isGenerator
$matcherFactory
$subject

Méthodes publiques

Méthode Description
__construct ( Eloquent\Phony\Spy\Spy | Eloquent\Phony\Call\Call $subject, array $calls, MatcherFactory $matcherFactory, CallVerifierFactory $callVerifierFactory, Eloquent\Phony\Assertion\AssertionRecorder $assertionRecorder, AssertionRenderer $assertionRenderer ) Construct a new iterable verifier.
checkConsumed ( ) : Eloquent\Phony\Event\EventCollection | null Checks if the subject was completely consumed.
checkProduced ( mixed $keyOrValue = null, mixed $value = null ) : Eloquent\Phony\Event\EventCollection | null Checks if the subject produced the supplied values.
checkUsed ( ) : Eloquent\Phony\Event\EventCollection | null Checks if iteration of the subject commenced.
consumed ( ) : Eloquent\Phony\Event\EventCollection Throws an exception unless the subject was completely consumed.
produced ( mixed $keyOrValue = null, mixed $value = null ) : Eloquent\Phony\Event\EventCollection Throws an exception unless the subject produced the supplied values.
used ( ) : Eloquent\Phony\Event\EventCollection Throws an exception unless iteration of the subject commenced.

Method Details

__construct() public méthode

Construct a new iterable verifier.
public __construct ( Eloquent\Phony\Spy\Spy | Eloquent\Phony\Call\Call $subject, array $calls, MatcherFactory $matcherFactory, CallVerifierFactory $callVerifierFactory, Eloquent\Phony\Assertion\AssertionRecorder $assertionRecorder, AssertionRenderer $assertionRenderer )
$subject Eloquent\Phony\Spy\Spy | Eloquent\Phony\Call\Call The subject.
$calls array
$matcherFactory Eloquent\Phony\Matcher\MatcherFactory The matcher factory to use.
$callVerifierFactory Eloquent\Phony\Call\CallVerifierFactory The call verifier factory to use.
$assertionRecorder Eloquent\Phony\Assertion\AssertionRecorder The assertion recorder to use.
$assertionRenderer Eloquent\Phony\Assertion\AssertionRenderer The assertion renderer to use.

checkConsumed() public méthode

Checks if the subject was completely consumed.
public checkConsumed ( ) : Eloquent\Phony\Event\EventCollection | null
Résultat Eloquent\Phony\Event\EventCollection | null The result.

checkProduced() public méthode

When called with no arguments, this method simply checks that the subject produced any value. With a single argument, it checks that a value matching the argument was produced. With two arguments, it checks that a key and value matching the respective arguments were produced together.
public checkProduced ( mixed $keyOrValue = null, mixed $value = null ) : Eloquent\Phony\Event\EventCollection | null
$keyOrValue mixed The key or value.
$value mixed The value.
Résultat Eloquent\Phony\Event\EventCollection | null The result.

checkUsed() public méthode

Checks if iteration of the subject commenced.
public checkUsed ( ) : Eloquent\Phony\Event\EventCollection | null
Résultat Eloquent\Phony\Event\EventCollection | null The result.

consumed() public méthode

Throws an exception unless the subject was completely consumed.
public consumed ( ) : Eloquent\Phony\Event\EventCollection
Résultat Eloquent\Phony\Event\EventCollection The result.

produced() public méthode

When called with no arguments, this method simply checks that the subject produced any value. With a single argument, it checks that a value matching the argument was produced. With two arguments, it checks that a key and value matching the respective arguments were produced together.
public produced ( mixed $keyOrValue = null, mixed $value = null ) : Eloquent\Phony\Event\EventCollection
$keyOrValue mixed The key or value.
$value mixed The value.
Résultat Eloquent\Phony\Event\EventCollection The result.

used() public méthode

Throws an exception unless iteration of the subject commenced.
public used ( ) : Eloquent\Phony\Event\EventCollection
Résultat Eloquent\Phony\Event\EventCollection The result.

Property Details

$assertionRecorder protected_oe property

protected $assertionRecorder

$assertionRenderer protected_oe property

protected $assertionRenderer

$isGenerator protected_oe property

protected $isGenerator

$matcherFactory protected_oe property

protected $matcherFactory

$subject protected_oe property

protected $subject