diff --git a/src/Symfony/Bundle/FrameworkBundle/Tests/Command/CacheClearCommand/CacheClearCommandTest.php b/src/Symfony/Bundle/FrameworkBundle/Tests/Command/CacheClearCommand/CacheClearCommandTest.php index 4b557011a9..27f2973d82 100644 --- a/src/Symfony/Bundle/FrameworkBundle/Tests/Command/CacheClearCommand/CacheClearCommandTest.php +++ b/src/Symfony/Bundle/FrameworkBundle/Tests/Command/CacheClearCommand/CacheClearCommandTest.php @@ -18,6 +18,7 @@ use Symfony\Component\Config\ConfigCacheFactory; use Symfony\Component\Config\Resource\ResourceInterface; use Symfony\Component\Console\Input\ArrayInput; use Symfony\Component\Console\Output\NullOutput; +use Symfony\Component\Filesystem\Exception\IOException; use Symfony\Component\Filesystem\Filesystem; use Symfony\Component\Finder\Finder; @@ -37,7 +38,10 @@ class CacheClearCommandTest extends TestCase protected function tearDown(): void { - $this->fs->remove($this->kernel->getProjectDir()); + try { + $this->fs->remove($this->kernel->getProjectDir()); + } catch (IOException $e) { + } } public function testCacheIsFreshAfterCacheClearedWithWarmup()