Level 1
I fixed it by cleaning up the compiled files when the test environment is set up. Despite working, I don't think it's a good solution.
protected function setUp(): void
{
parent::setUp();
$this->artisan('clear-compiled');
}
Deferred providers use a cached manifest (bootstrap/cache/services.php) that skips methods like provides() during tests, lowering coverage. What's the recommended way to bypass or disable this cache in the test environment?
Please or to participate in this conversation.