trait InteractsWithContainer (View source)
protected Mix|null | $originalMix | The original Laravel Mix handler. |
object | swap(string $abstract, object $instance) Register an instance of an object in the container. | |
object | instance(string $abstract, object $instance) Register an instance of an object in the container. | |
MockInterface | mock(string $abstract, Closure $mock = null) Mock an instance of an object in the container. | |
MockInterface | partialMock(string $abstract, Closure $mock = null) Mock a partial instance of an object in the container. | |
MockInterface | spy(string $abstract, Closure $mock = null) Spy an instance of an object in the container. | |
$this | withoutMix() Register an empty handler for Laravel Mix in the container. | |
$this | withMix() Register an empty handler for Laravel Mix in the container. |
Register an instance of an object in the container.
Register an instance of an object in the container.
Mock an instance of an object in the container.
Mock a partial instance of an object in the container.
Spy an instance of an object in the container.
Register an empty handler for Laravel Mix in the container.
Register an empty handler for Laravel Mix in the container.
© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/8.x/Illuminate/Foundation/Testing/Concerns/InteractsWithContainer.html