add trend UX + PHPStan level 6 clean (0 errors)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
13
backend/tests/bootstrap_phpstan.php
Normal file
13
backend/tests/bootstrap_phpstan.php
Normal file
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
use App\Kernel;
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Variables minimales pour booter le kernel sans vraie DB
|
||||
$_ENV['DATABASE_URL'] = $_ENV['DATABASE_URL'] ?? 'postgresql://user:pass@localhost:5432/phpstan_dummy?serverVersion=16';
|
||||
$_ENV['APP_SECRET'] = $_ENV['APP_SECRET'] ?? 'phpstan-dummy-secret';
|
||||
$_SERVER['DATABASE_URL'] = $_ENV['DATABASE_URL'];
|
||||
$_SERVER['APP_SECRET'] = $_ENV['APP_SECRET'];
|
||||
|
||||
$kernel = new Kernel('dev', true);
|
||||
$kernel->boot();
|
||||
return $kernel->getContainer()->get('doctrine')->getManager();
|
||||
Reference in New Issue
Block a user