예제 #1
0
 function testTreeMove()
 {
     mkdir(SABRE_TEMPDIR . '/issue33');
     $dir = new FS\Directory(SABRE_TEMPDIR . '/issue33');
     $dir->createDirectory('bar');
     $tree = new ObjectTree($dir);
     $tree->move('bar', urldecode('%C3%A0fo%C3%B3'));
     $node = $tree->getNodeForPath(urldecode('%C3%A0fo%C3%B3'));
     $this->assertEquals(urldecode('%C3%A0fo%C3%B3'), $node->getName());
 }
 /**
  * add vacation template file to vfs
  */
 protected function _addVacationTemplateFile()
 {
     $webdavRoot = new DAV\ObjectTree(new Tinebase_WebDav_Root());
     $path = '/webdav/Felamimail/shared/Vacation Templates';
     $node = $webdavRoot->getNodeForPath($path);
     $this->_pathsToDelete[] = $path . '/' . $this->_sieveVacationTemplateFile;
     $node->createFile($this->_sieveVacationTemplateFile, fopen(dirname(__FILE__) . '/../files/' . $this->_sieveVacationTemplateFile, 'r'));
 }