- Does facile-it/symfony-functional-testcase work with Laravel?
- No. It is a Symfony functional-testing helper that subclasses Symfony's WebTestCase to boot the test kernel and wrap KernelBrowser. Laravel applications have no architectural home for it unless you also maintain a Symfony service, bundle, or shared package that uses it. For Laravel-only projects, stick with Laravel's own HTTP testing helpers.
- How do I install facile-it/symfony-functional-testcase?
- Install it as a dev dependency with composer require --dev facile-it/symfony-functional-testcase. Version 1.5.0 requires PHP 8.1 or newer and Symfony 5.4 or newer. Because it touches only the test bootstrap layer, it should stay in require-dev and never ship to production.
- Which PHP and Symfony versions are supported by version 1.5.0?
- Release 1.5.0 sets a floor of PHP 8.1 and Symfony 5.4, dropping older platforms. The release notes do not publish a tested upper bound, so support for Symfony 7 and PHP 8.4 must be verified against your own CI matrix. If any consuming repo still runs PHP 8.0, that service must upgrade before it can take 1.5.0.
- How do I make GET, POST, PUT, PATCH and DELETE requests in a Symfony functional test?
- Extend the package's base test case and use its chainable request helpers for each HTTP verb. The helpers wrap Symfony's KernelBrowser, so you avoid writing boilerplate client setup in every test. You can then chain assertions directly onto the response.
- How do I authenticate a user in Symfony functional tests with this package?
- The package includes built-in authentication and user-switching utilities, so you can log in as a user without hand-rolling the login flow. This keeps tests focused on the behaviour under test rather than session and security setup. Check the README for the exact helper names in your installed version.
- What assertions does the package provide?
- It provides JSON, header, and status-code assertions out of the box, intended to be chained after a request. These cover the common functional-test checks without extra PHPUnit assertions or manual response decoding. For anything unusual, you can still fall back to the underlying KernelBrowser response.
- Why is getDependencyInjectionContainer() deprecated and what should I use instead?
- Release 1.5.0 deprecates WebTestCase::getDependencyInjectionContainer() in favour of Symfony's native getContainer(). The replacement is a find-and-replace across test files with low blast radius. Verify tests that lazily fetch private services, because container access semantics for private services can differ.
- Can I use facile-it/symfony-functional-testcase in production?
- No. It is a test-only dependency that only touches the test bootstrap layer, with no production runtime coupling, routing, persistence, or framework bootstrapping. Keep it in require-dev. Shipping it to production adds no value and only expands your dependency surface.
- What are the alternatives to this package?
- The main alternative is Symfony's own WebTestCase and KernelBrowser, which this package wraps with a thinner, fluent API. If you only need occasional functional tests, native Symfony testing may be enough. If you want concise, chainable request and assertion helpers, this package reduces boilerplate.
- Is this package maintained, and what is the bus factor?
- Release 1.5.0 is a maintenance release, but the context does not state a maintainer count, release cadence, or deprecation policy. The removal timeline for getDependencyInjectionContainer() is unstated, which makes scheduling cleanup harder. Confirm direct versus transitive usage and identify the owning team before relying on it long term.