feat: upgrade phpunit to 12.5

This commit is contained in:
Björn Fromme
2026-08-31 09:31:00 +02:00
parent 010cfe56b2
commit bfad61f1dd
95 changed files with 1436 additions and 1224 deletions
@@ -9,6 +9,7 @@ use App\Entity\Groups\Accommodation;
use App\Entity\Groups\AccommodationBooking;
use App\Enum\Groups\AccommodationBookingStatus;
use App\Service\AccommodationBookingService;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\TestCase;
use Psr\Log\LoggerInterface;
use Symfony\Component\Form\FormInterface;
@@ -34,9 +35,7 @@ class ChangeAccommodationControllerTest extends TestCase
self::assertSame('admin/accommodation_booking/modal_change_accommodation.html.twig', $controller->renderedView);
}
/**
* @dataProvider lockedStatuses
*/
#[DataProvider('lockedStatuses')]
public function testABookingThatHasLeftEntwurfCannotMoveHouse(AccommodationBookingStatus $status): void
{
// The customer may already be looking at the offer under their access link.
@@ -127,7 +126,7 @@ class ChangeAccommodationControllerTest extends TestCase
private function unsubmittedForm(): FormInterface
{
$form = $this->createMock(FormInterface::class);
$form = $this->createStub(FormInterface::class);
$form->method('handleRequest')->willReturn($form);
$form->method('isSubmitted')->willReturn(false);
@@ -136,7 +135,7 @@ class ChangeAccommodationControllerTest extends TestCase
private function submittedForm(Accommodation $selected): FormInterface
{
$field = $this->createMock(FormInterface::class);
$field = $this->createStub(FormInterface::class);
$field->method('getData')->willReturn($selected);
$form = $this->createMock(FormInterface::class);
@@ -154,7 +153,7 @@ class ChangeAccommodationControllerTest extends TestCase
): TestableChangeAccommodationController {
return new TestableChangeAccommodationController(
$bookingService,
$this->createMock(LoggerInterface::class),
$this->createStub(LoggerInterface::class),
$form,
);
}