From 6a917e6b87806263f7ebd7d5c1920400ecbe9e56 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 4 Sep 2024 21:01:38 +0100 Subject: [PATCH] Fix post test clean up for temporary files Signed-off-by: George Steel --- test/StreamTest.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/StreamTest.php b/test/StreamTest.php index 6cd978c5..498bdff2 100644 --- a/test/StreamTest.php +++ b/test/StreamTest.php @@ -58,7 +58,11 @@ protected function tearDown(): void if (is_string($this->tmpnam) && file_exists($this->tmpnam)) { unlink($this->tmpnam); } + } + public static function tearDownAfterClass(): void + { + /** @see self::invalidResources() */ foreach (self::$tempFiles as $tempFile) { if (! file_exists($tempFile)) { continue;