chore: upgrade phpunit to 12.5

This commit is contained in:
fromme committed 2026-10-01 10:07:05 +02:00
1 parent da039d0527
commit 849da8d471
53 files changed
+832 -856

No files matched your search

+5 -4
View File
@@ -11,6 +11,7 @@ use App\MyEp\Import\TravelExport;
use App\MyEp\Import\TravelExportClient;
use Doctrine\DBAL\Connection;
use PHPUnit\Framework\MockObject\MockObject;
use PHPUnit\Framework\MockObject\Stub;
use PHPUnit\Framework\TestCase;
use Psr\Log\NullLogger;
use Symfony\Component\Console\Command\Command;
@@ -87,7 +88,7 @@ class MyEpImportCommandTest extends TestCase
public function testItRefusesToRunWhenTheExportCannotBeRead(): void
{
$client = $this->createMock(TravelExportClient::class);
$client = $this->createStub(TravelExportClient::class);
$client->method('fetchAll')->willThrowException(new ApiException('gateway timeout'));
$tester = new CommandTester(new MyEpImportCommand(
@@ -184,7 +185,7 @@ class MyEpImportCommandTest extends TestCase
int $skipped = 0,
int $pickupsWithoutMasterData = 0,
): CommandTester {
$client = $this->createMock(TravelExportClient::class);
$client = $this->createStub(TravelExportClient::class);
$client->method('fetchAll')->willReturn(
new TravelExport($rows, $skipped, $pickupsWithoutMasterData, '2026-09-29T03:20:00+02:00')
);
@@ -212,9 +213,9 @@ class MyEpImportCommandTest extends TestCase
return $connection;
}
private function writingConnection(int $existingId): Connection&MockObject
private function writingConnection(int $existingId): Connection&Stub
{
$connection = $this->createMock(Connection::class);
$connection = $this->createStub(Connection::class);
$connection->method('fetchOne')->willReturn($existingId);
return $connection;