fix unit tests
This commit is contained in:
parent
3d0805f27d
commit
d3d1955ef4
|
@ -248,14 +248,14 @@ class Test_Encryption_Keymanager extends \PHPUnit_Framework_TestCase {
|
||||||
|
|
||||||
function testKeySetPreperation() {
|
function testKeySetPreperation() {
|
||||||
$basePath = '/'.Test_Encryption_Keymanager::TEST_USER.'/files';
|
$basePath = '/'.Test_Encryption_Keymanager::TEST_USER.'/files';
|
||||||
$path = '/folder1/subfolder/subsubfolder';
|
$path = '/folder1/subfolder/subsubfolder/file.txt';
|
||||||
|
|
||||||
$this->assertFalse($this->view->is_dir($basePath . '/testKeySetPreperation'));
|
$this->assertFalse($this->view->is_dir($basePath . '/testKeySetPreperation'));
|
||||||
|
|
||||||
$result = TestProtectedKeymanagerMethods::testKeySetPreperation($this->view, $path, $basePath);
|
$result = TestProtectedKeymanagerMethods::testKeySetPreperation($this->view, $path, $basePath);
|
||||||
|
|
||||||
// return path without leading slash
|
// return path without leading slash
|
||||||
$this->assertSame('folder1/subfolder/subsubfolder', $result);
|
$this->assertSame('folder1/subfolder/subsubfolder/file.txt', $result);
|
||||||
|
|
||||||
// check if directory structure was created
|
// check if directory structure was created
|
||||||
$this->assertTrue($this->view->is_dir($basePath . '/folder1/subfolder/subsubfolder'));
|
$this->assertTrue($this->view->is_dir($basePath . '/folder1/subfolder/subsubfolder'));
|
||||||
|
|
Loading…
Reference in New Issue