exists() public method

public exists ( )
Example #1
0
 public function testExists()
 {
     $this->given($adapter = new atoum\test\adapter())->and($path = new testedClass(uniqid(), '/', $adapter))->then->if($adapter->file_exists = false)->then->boolean($path->exists())->isFalse()->adapter($adapter)->call('file_exists')->withArguments((string) $path)->once()->if($adapter->file_exists = true)->then->boolean($path->exists())->isTrue()->adapter($adapter)->call('file_exists')->withArguments((string) $path)->twice();
 }