diff --git a/tests/PHPStan/Analyser/nsrt/bug-11311.php b/tests/PHPStan/Analyser/nsrt/bug-11311.php index e707a93608..40cbb49557 100644 --- a/tests/PHPStan/Analyser/nsrt/bug-11311.php +++ b/tests/PHPStan/Analyser/nsrt/bug-11311.php @@ -3,6 +3,7 @@ namespace Bug11311; use function PHPStan\Testing\assertType; +use InvalidArgumentException; function doFoo(string $s) { if (1 === preg_match('/(?\d+)\.(?\d+)(?:\.(?\d+))?/', $s, $matches, PREG_UNMATCHED_AS_NULL)) { diff --git a/tests/PHPStan/Analyser/nsrt/preg_match_shapes.php b/tests/PHPStan/Analyser/nsrt/preg_match_shapes.php index 5345cd5501..c3211a9d75 100644 --- a/tests/PHPStan/Analyser/nsrt/preg_match_shapes.php +++ b/tests/PHPStan/Analyser/nsrt/preg_match_shapes.php @@ -3,7 +3,7 @@ namespace PregMatchShapes; use function PHPStan\Testing\assertType; - +use InvalidArgumentException; function doMatch(string $s): void { if (preg_match('/Price: /i', $s, $matches)) {