From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit@debian.org>
Date: Wed, 19 Feb 2025 03:53:54 +0100
Subject: Modernize PHPUnit syntax

---
 test/EventManagerTest.php                         | 2 +-
 test/LazyListenerAggregateTest.php                | 2 +-
 test/Test/EventListenerIntrospectionTraitTest.php | 2 ++
 3 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/test/EventManagerTest.php b/test/EventManagerTest.php
index 854de36..6d6f8bb 100644
--- a/test/EventManagerTest.php
+++ b/test/EventManagerTest.php
@@ -58,7 +58,7 @@ class EventManagerTest extends TestCase
         $value = $r->getValue($manager);
         self::assertIsArray($value);
         $keys = array_keys($value);
-        self::assertContainsOnly('string', $keys);
+        self::assertContainsOnlyString($keys);
         /** @psalm-var list<string> */
 
         return $keys;
diff --git a/test/LazyListenerAggregateTest.php b/test/LazyListenerAggregateTest.php
index 480d2b7..f9144c5 100644
--- a/test/LazyListenerAggregateTest.php
+++ b/test/LazyListenerAggregateTest.php
@@ -182,7 +182,7 @@ class LazyListenerAggregateTest extends TestCase
         $events = $this->createMock(EventManagerInterface::class);
         $events->expects(self::once())
             ->method('attach')
-            ->with('event', self::isType('callable'), 1)
+            ->with('event', self::isCallable(), 1)
             ->willReturnArgument(1);
 
         $listeners = [
diff --git a/test/Test/EventListenerIntrospectionTraitTest.php b/test/Test/EventListenerIntrospectionTraitTest.php
index ee7e484..d519fbc 100644
--- a/test/Test/EventListenerIntrospectionTraitTest.php
+++ b/test/Test/EventListenerIntrospectionTraitTest.php
@@ -35,6 +35,7 @@ class EventListenerIntrospectionTraitTest extends TestCase
         self::assertEquals(['foo', 'bar', 'baz'], $this->getEventsFromEventManager($this->events));
     }
 
+    #[\PHPUnit\Framework\Attributes\Group('nophpunit12')]
     public function testGetListenersForEventReturnsIteratorOfListenersForEventInPriorityOrder(): void
     {
         // @codingStandardsIgnoreStart
@@ -122,6 +123,7 @@ class EventListenerIntrospectionTraitTest extends TestCase
         ], $listeners);
     }
 
+    #[\PHPUnit\Framework\Attributes\Group('nophpunit12')]
     public function testGetArrayOfListenersForEventReturnsArrayOfListenersInPriorityOrder(): void
     {
         // @codingStandardsIgnoreStart
