ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
Twig_Tests_FilesystemHelper Class Reference
+ Collaboration diagram for Twig_Tests_FilesystemHelper:

Static Public Member Functions

static removeDir ($dir)
 

Detailed Description

Definition at line 12 of file FilesystemHelper.php.

Member Function Documentation

◆ removeDir()

static Twig_Tests_FilesystemHelper::removeDir (   $dir)
static

Definition at line 14 of file FilesystemHelper.php.

15 {
16 $iterator = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($dir, PHP_VERSION_ID < 50300 ? 0 : FilesystemIterator::SKIP_DOTS), RecursiveIteratorIterator::CHILD_FIRST);
17 foreach ($iterator as $filename => $fileInfo) {
18 if ($iterator->isDot()) {
19 continue;
20 }
21
22 if ($fileInfo->isDir()) {
23 rmdir($filename);
24 } else {
25 unlink($filename);
26 }
27 }
28 rmdir($dir);
29 }

References $filename.

Referenced by Twig_Tests_FileCachingTest\tearDown(), and Twig_Tests_EnvironmentTest\testExtensionsAreNotInitializedWhenRenderingACompiledTemplate().

+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: