Skip to content

Commit 47cbe91

Browse files
committed
test: fix psalm for phpunit 11.4
1 parent d5b06dd commit 47cbe91

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

test/unit/ExceptionDetailsTraitTest.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,15 +52,18 @@ public function testOnNotSuccessfulTest_GivenException_SetsSameExceptionAsLast()
5252
}
5353
}
5454

55+
/**
56+
* CoversTrait was added in PHPUnit 11.2.0.
57+
* If was then deprecated in 11.4.0 but the deprecation was reverted in 11.5.4.
58+
* @psalm-suppress DeprecatedClass
59+
*/
5560
if (class_exists(CoversTrait::class)) {
56-
// Since PHPUnit 11.2.0 (deprecation has been reverted in 11.5.4)
5761
#[CoversTrait(ExceptionDetailsTrait::class)]
5862
final class ExceptionDetailsTraitTest extends ExceptionDetailsTraitTestBase
5963
{
6064
}
6165

6266
} else {
63-
// For PHPUnit <11.2.0
6467
#[CoversClass(ExceptionDetailsTrait::class)]
6568
final class ExceptionDetailsTraitTest extends ExceptionDetailsTraitTestBase
6669
{

0 commit comments

Comments
 (0)