Skip to content

Commit 6aee07e

Browse files
committed
feat: fix PHP 8.4 deprecations
1 parent 028181b commit 6aee07e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/Knp/Snappy/PdfTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
use CallbackFilterIterator;
1111
use DirectoryIterator;
1212
use ReflectionMethod;
13+
use RuntimeException;
1314

1415
class PdfTest extends TestCase
1516
{
@@ -79,8 +80,9 @@ public function testRemovesLocalFilesOnError(): void
7980
$method->setAccessible(true);
8081
$method->invoke($pdf, 'test', $pdf->getDefaultExtension());
8182
$this->assertEquals(1, \count($pdf->temporaryFiles));
82-
$this->expectException(\RuntimeException::class);
83-
throw new \RuntimeException('test error');
83+
$this->expectException(RuntimeException::class);
84+
85+
throw new RuntimeException('test error');
8486
// @phpstan-ignore-next-line See https://github.com/phpstan/phpstan/issues/7799
8587
$this->assertFileNotExists(\reset($pdf->temporaryFiles));
8688
}

0 commit comments

Comments
 (0)