scandir call doesn't return '.' and '..' pseudofolders
Hi.
It seems that php-vfs doesn't return default . and .. pseudo folders on scandir call, so i'm having problems in setting up an environment that would repeat real one.
Can you show me how are you initialising the filesystem?
Sent from my phone.
On 17 May 2015, at 06:30, Etki [email protected] wrote:
Hi. It seems that php-vfs doesn't return default . and .. pseudo folders on scandir call, so i'm having problems in setting up an environment that would repeat real one.
— Reply to this email directly or view it on GitHub.
Here it goes
use VirtualFileSystem\FileSystem as VFS;
class CleanerTest extends AbstractTest
{
// ...
protected function setUp()
{
$this->vfs = new VFS;
}
protected function tearDown()
{
unset($this->vfs);
}
private function getVfsRoot()
{
return $this->vfs->path('/');
}
public function testCleaner()
{
// ...
$initialContent = scandir($this->getVfsRoot());
// ...
}
// ...
}
I've tried to use /tmp (non-root directory) as well, but it returned empty array on scandir() as well.