예제 #1
0
 public function testGetRelativePathOnNull()
 {
     $view = new \OC\Files\View();
     $this->assertNull($view->getRelativePath(null));
 }
예제 #2
0
 /**
  * @dataProvider relativePathProvider
  */
 function testGetRelativePath($absolutePath, $expectedPath)
 {
     $view = new \OC\Files\View('/files');
     // simulate a external storage mount point which has a trailing slash
     $view->chroot('/files/');
     $this->assertEquals($expectedPath, $view->getRelativePath($absolutePath));
 }