org\bovigo\vfs\vfsStreamWrapperMkDirTestCase::unlinkCanNotRemoveEmptyDirectory PHP Method

unlinkCanNotRemoveEmptyDirectory() public method

Since: 0.11.0
    public function unlinkCanNotRemoveEmptyDirectory()
    {
        vfsStream::newDirectory('empty')->at($this->foo);
        try {
            $this->assertTrue(unlink($this->fooURL . '/empty'));
        } catch (\PHPUnit_Framework_Error $fe) {
            $this->assertEquals('unlink(vfs://foo/empty): Operation not permitted', $fe->getMessage());
        }
        $this->assertTrue($this->foo->hasChild('empty'));
        $this->assertFileExists($this->fooURL . '/empty');
    }