Метод |
Описание |
|
__construct ( callable | null $callback, mixed $self, string | null $label, callable $defaultAnswerCallback, MatcherFactory $matcherFactory, MatcherVerifier $matcherVerifier, Invoker $invoker, InvocableInspector $invocableInspector, EmptyValueFactory $emptyValueFactory, GeneratorAnswerBuilderFactory $generatorAnswerBuilderFactory ) |
Construct a new stub data instance. |
|
calls ( callable $callback ) |
Add a callback to be called as part of an answer. |
|
callsArgument ( integer $index ) |
Add an argument callback to be called as part of an answer. |
|
callsArgumentWith ( integer $index, Arguments | array $arguments = [], boolean $prefixSelf = false, boolean $suffixArgumentsObject = false, boolean $suffixArguments = false ) |
Add an argument callback to be called as part of an answer. |
|
callsWith ( callable $callback, Arguments | array $arguments = [], boolean | null $prefixSelf = null, boolean $suffixArgumentsObject = false, boolean $suffixArguments = true ) |
Add a callback to be called as part of an answer. |
|
closeRule ( ) |
Close any existing rule. |
|
defaultAnswerCallback ( ) : callable |
Get the default answer callback. |
|
does ( callable $callback ) |
Add a callback as an answer. |
|
doesWith ( callable $callback, Arguments | array $arguments = [], boolean | null $prefixSelf = null, boolean $suffixArgumentsObject = false, boolean $suffixArguments = true ) |
Add a callback as an answer. |
|
forwards ( Arguments | array $arguments = [], boolean | null $prefixSelf = null, boolean $suffixArgumentsObject = false, boolean $suffixArguments = true ) |
Add an answer that calls the wrapped callback. |
|
forwardsAnswerCallback ( Eloquent\Phony\Stub\Stub $stub ) |
Creates a "forwards" answer on the supplied stub. |
|
generates ( mixed>\mixed $values = [] ) : Eloquent\Phony\Stub\Answer\Builder\GeneratorAnswerBuilder |
Add an answer that returns a generator, and return a builder for
customizing the generator's behavior. |
|
invokeWith ( Arguments | array $arguments = [] ) : mixed |
Invoke this object. |
|
returns ( mixed $value = null ) |
Add an answer that returns a value. |
|
returnsArgument ( integer $index ) |
Add an answer that returns an argument. |
|
returnsEmptyAnswerCallback ( Eloquent\Phony\Stub\Stub $stub ) |
Creates an answer that returns an empty value on the supplied stub. |
|
returnsSelf ( ) |
Add an answer that returns the self value. |
|
self ( ) : mixed |
Get the self value of this stub. |
|
setDefaultAnswerCallback ( callable $defaultAnswerCallback ) |
Set the callback to use when creating a default answer. |
|
setSelf ( mixed $self ) |
Set the self value of this stub. |
|
setsArgument ( mixed $indexOrValue = null, mixed $value = null ) |
Set the value of an argument passed by reference as part of an answer. |
|
throws ( Exceptio\Exception | Erro\Error | string | null $exception = null ) |
Add an answer that throws an exception. |
|
with ( ) |
Modify the current criteria to match the supplied arguments. |
|