Download the PHP package bentools/pest-symfony-kernel without Composer
On this page you can find all versions of the php package bentools/pest-symfony-kernel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download bentools/pest-symfony-kernel
More information about bentools/pest-symfony-kernel
Files in bentools/pest-symfony-kernel
Package pest-symfony-kernel
Short Description Symfony Kernel and dependency injection for Pest
License MIT
Informations about the package pest-symfony-kernel
Symfony DI Container for Pest
Symfony Kernel and dependency injection for Pest PHP.
This library provides a simple way to access the Symfony kernel, container, and services in your Pest tests, making it easier to write integration tests for Symfony applications.
Requirements
- PHP 8.2+
- Pest PHP 2.35+ or 3.0+
- Symfony 6.4+ or 7.x
Installation
Usage
How It Works
This library provides three main functions under the BenTools\Pest\Symfony
namespace:
app()
: Creates and returns a Symfony kernel instance for testingcontainer()
: Gets the test service container from the kernelinject()
: Retrieves a service from the container by its ID
These functions make it easier to work with Symfony's dependency injection container in Pest tests, allowing for simpler access to the application kernel, container, and services.
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
License
MIT.
All versions of pest-symfony-kernel with dependencies
ext-ctype Version *
ext-iconv Version *
pestphp/pest Version ~2.35|~3.0
symfony/framework-bundle Version ~6.4 | ~7.1