Documentation

InvocationStubber

Tags
no-named-arguments

Parameter names are not covered by the backward compatibility promise for PHPUnit

Table of Contents

Methods

will()  : Identity
willReturn()  : $this
willReturnArgument()  : $this
willReturnCallback()  : $this
willReturnMap()  : $this
willReturnOnConsecutiveCalls()  : $this
willReturnReference()  : $this
willReturnSelf()  : $this
willThrowException()  : $this

Methods

will()

public will(Stub $stub) : Identity
Parameters
$stub : Stub
Return values
Identity

willReturn()

public willReturn(mixed $value, mixed ...$nextValues) : $this
Parameters
$value : mixed
$nextValues : mixed
Return values
$this

willReturnArgument()

public willReturnArgument(int $argumentIndex) : $this
Parameters
$argumentIndex : int
Return values
$this

willReturnCallback()

public willReturnCallback(callable $callback) : $this
Parameters
$callback : callable
Return values
$this

willReturnMap()

public willReturnMap(array<int, array<int, mixed>> $valueMap) : $this
Parameters
$valueMap : array<int, array<int, mixed>>
Return values
$this

willReturnOnConsecutiveCalls()

public willReturnOnConsecutiveCalls(mixed ...$values) : $this
Parameters
$values : mixed
Return values
$this

willReturnReference()

public willReturnReference(mixed &$reference) : $this
Parameters
$reference : mixed
Return values
$this

willThrowException()

public willThrowException(Throwable $exception) : $this
Parameters
$exception : Throwable
Return values
$this
On this page

Search results