[Config] Fixed tests on Windows
This commit is contained in:
parent
237629ad64
commit
65281fb56c
@ -38,7 +38,7 @@ class DirectoryResourceTest extends \PHPUnit_Framework_TestCase
|
|||||||
{
|
{
|
||||||
$iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory), \RecursiveIteratorIterator::CHILD_FIRST);
|
$iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory), \RecursiveIteratorIterator::CHILD_FIRST);
|
||||||
foreach ($iterator as $path) {
|
foreach ($iterator as $path) {
|
||||||
if (preg_match('#/\.\.?$#', $path->__toString())) {
|
if (preg_match('#[/\\\\]\.\.?$#', $path->__toString())) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if ($path->isDir()) {
|
if ($path->isDir()) {
|
||||||
|
Reference in New Issue
Block a user