++ fix e controlli

This commit is contained in:
2026-07-30 17:05:39 +02:00
parent 712336d652
commit 440d63a6b9
54 changed files with 4921 additions and 1322 deletions

24
tests/TestCase.php Normal file
View File

@@ -0,0 +1,24 @@
<?php
namespace Tests;
use Illuminate\Contracts\Console\Kernel;
use Illuminate\Foundation\Application;
use Illuminate\Foundation\Testing\TestCase as BaseTestCase;
abstract class TestCase extends BaseTestCase
{
/**
* L'applicazione si costruisce dallo stesso bootstrap/app.php che usa il
* runtime: middleware, provider e rotte sono quelli veri, cosi' un test non
* puo' passare grazie a una configurazione che esiste solo nei test.
*/
public function createApplication(): Application
{
$app = require __DIR__ . '/../bootstrap/app.php';
$app->make(Kernel::class)->bootstrap();
return $app;
}
}