Final Class Yiisoft\PsrEmitter\FakeEmitter
| Inheritance | Yiisoft\ |
|---|---|
| Implements | Yiisoft\ |
FakeEmitter is a test implementation of EmitterInterface that captures the last emitted response.
Public Methods
| Method | Description | Defined By |
|---|---|---|
| emit() | Yiisoft\ |
|
| getLastResponse() | Yiisoft\ |
Method Details
| public void emit ( \ | ||
| $response | \ |
|
public function emit(ResponseInterface $response): void
{
$this->response = $response;
}
| public \ | ||
| return | \ |
The last emitted response or |
|---|---|---|
public function getLastResponse(): ?ResponseInterface
{
return $this->response;
}
User Contributed Notes
Leave a comment
Join the conversation to share a note.