Allow opening folder lisings on client
Some checks failed
DokuWiki Default Tasks / all (push) Has been cancelled
Some checks failed
DokuWiki Default Tasks / all (push) Has been cancelled
This commit is contained in:
@@ -110,4 +110,13 @@ EOT
|
||||
$this->expectExceptionMessageMatches('/Path not allowed/');
|
||||
$this->path->getPathInfo($path);
|
||||
}
|
||||
|
||||
public function testMapToAliasPath()
|
||||
{
|
||||
$mapped = $this->path->mapToAliasPath('/linux/another/path/some/folder');
|
||||
$this->assertEquals('alias/some/folder', $mapped);
|
||||
|
||||
$unmapped = $this->path->mapToAliasPath('/linux/file/path/example.txt');
|
||||
$this->assertEquals('/linux/file/path/example.txt', $unmapped);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@ class plugin_luxtools_test extends DokuWikiTest
|
||||
parent::setUp();
|
||||
|
||||
// Setup config so that access to the TMP directory will be allowed
|
||||
$conf ['plugin']['luxtools']['paths'] = TMP_DIR . '/filelistdata/' . "\n" . 'W> http://localhost/';
|
||||
$conf ['plugin']['luxtools']['paths'] = TMP_DIR . '/filelistdata/' . "\n" . 'A> /Scape' . "\n" . 'W> http://localhost/';
|
||||
|
||||
}
|
||||
|
||||
@@ -288,6 +288,6 @@ class plugin_luxtools_test extends DokuWikiTest
|
||||
$this->assertStringNotContainsString('example2.txt', $xhtml);
|
||||
|
||||
// Directory row should trigger the same behaviour as {{open>...}} for that folder
|
||||
$this->assertStringContainsString('data-path="' . TMP_DIR . '/filelistdata/exampledir"', $xhtml);
|
||||
$this->assertStringContainsString('data-path="/Scape/exampledir"', $xhtml);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user