예제 #1
0
 /**
  * Create package directory
  *
  * @param integer $id Package ID
  * @return string Path to created directory
  */
 public function createDirectory($id)
 {
     $dir = $this->getPath($id);
     \Library\FileObject::mkdir($dir);
     return $dir;
 }
예제 #2
0
 public function testMkdirErrorDirectoryExists()
 {
     $pathname = vfsStream::newDirectory('test')->at($this->_root)->url();
     $this->setExpectedException('RuntimeException', "Error creating directory '{$pathname}': path exists");
     FileObject::mkdir($pathname);
 }