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
@@ -15,7 +15,7 @@ class BookingStatusRuleRegistryTest extends TestCase
{
public function testReturnsDefaultStatusWhenNoRulesMatch(): void
{
$rule = $this->createMock(BookingStatusRuleInterface::class);
$rule = $this->createStub(BookingStatusRuleInterface::class);
$rule->method('evaluate')->willReturn(false);
$rule->method('getPriority')->willReturn(100);
@@ -27,7 +27,7 @@ class BookingStatusRuleRegistryTest extends TestCase
public function testReturnsMatchingRuleStatus(): void
{
$rule = $this->createMock(BookingStatusRuleInterface::class);
$rule = $this->createStub(BookingStatusRuleInterface::class);
$rule->method('evaluate')->willReturn(true);
$rule->method('getStatus')->willReturn('O');
$rule->method('getPriority')->willReturn(100);
@@ -40,12 +40,12 @@ class BookingStatusRuleRegistryTest extends TestCase
public function testHigherPriorityRuleTakesPrecedence(): void
{
$lowPriorityRule = $this->createMock(BookingStatusRuleInterface::class);
$lowPriorityRule = $this->createStub(BookingStatusRuleInterface::class);
$lowPriorityRule->method('evaluate')->willReturn(true);
$lowPriorityRule->method('getStatus')->willReturn('L');
$lowPriorityRule->method('getPriority')->willReturn(50);
$highPriorityRule = $this->createMock(BookingStatusRuleInterface::class);
$highPriorityRule = $this->createStub(BookingStatusRuleInterface::class);
$highPriorityRule->method('evaluate')->willReturn(true);
$highPriorityRule->method('getStatus')->willReturn('H');
$highPriorityRule->method('getPriority')->willReturn(100);
@@ -66,12 +66,12 @@ class BookingStatusRuleRegistryTest extends TestCase
public function testFirstMatchingRuleWinsForSamePriority(): void
{
$firstMatchingRule = $this->createMock(BookingStatusRuleInterface::class);
$firstMatchingRule = $this->createStub(BookingStatusRuleInterface::class);
$firstMatchingRule->method('evaluate')->willReturn(true);
$firstMatchingRule->method('getStatus')->willReturn('A');
$firstMatchingRule->method('getPriority')->willReturn(100);
$secondMatchingRule = $this->createMock(BookingStatusRuleInterface::class);
$secondMatchingRule = $this->createStub(BookingStatusRuleInterface::class);
$secondMatchingRule->method('evaluate')->willReturn(true);
$secondMatchingRule->method('getStatus')->willReturn('B');
$secondMatchingRule->method('getPriority')->willReturn(100);
@@ -84,12 +84,12 @@ class BookingStatusRuleRegistryTest extends TestCase
public function testNonMatchingHighPriorityRuleDoesNotBlockLowerPriority(): void
{
$highPriorityRule = $this->createMock(BookingStatusRuleInterface::class);
$highPriorityRule = $this->createStub(BookingStatusRuleInterface::class);
$highPriorityRule->method('evaluate')->willReturn(false);
$highPriorityRule->method('getStatus')->willReturn('H');
$highPriorityRule->method('getPriority')->willReturn(100);
$lowPriorityRule = $this->createMock(BookingStatusRuleInterface::class);
$lowPriorityRule = $this->createStub(BookingStatusRuleInterface::class);
$lowPriorityRule->method('evaluate')->willReturn(true);
$lowPriorityRule->method('getStatus')->willReturn('L');
$lowPriorityRule->method('getPriority')->willReturn(50);
@@ -102,7 +102,7 @@ class BookingStatusRuleRegistryTest extends TestCase
public function testSelection1473RuleWinsOverLowerPriorityRule(): void
{
$lowerPriorityRule = $this->createMock(BookingStatusRuleInterface::class);
$lowerPriorityRule = $this->createStub(BookingStatusRuleInterface::class);
$lowerPriorityRule->method('evaluate')->willReturn(true);
$lowerPriorityRule->method('getStatus')->willReturn('X');
$lowerPriorityRule->method('getPriority')->willReturn(100);