0
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2024-12-22 16:31:53 +00:00

Increase test coverage for MakeAbsolute.

Signed-off-by: Edward Z. Yang <edwardzyang@thewritingpot.com>
This commit is contained in:
Edward Z. Yang 2008-08-13 23:19:38 -04:00
parent 617f70a8ac
commit 8423daef05

View File

@ -55,6 +55,10 @@ class HTMLPurifier_URIFilter_MakeAbsoluteTest extends HTMLPurifier_URIFilterHarn
$this->assertFiltering('.', 'http://example.com/foo/'); $this->assertFiltering('.', 'http://example.com/foo/');
} }
function testFilterRelativePathMultiDot() {
$this->assertFiltering('././foo/./bar/.././baz', 'http://example.com/foo/foo/baz');
}
function testFilterRelativePathWithInternalDotDot() { function testFilterRelativePathWithInternalDotDot() {
$this->assertFiltering('../baz.txt', 'http://example.com/baz.txt'); $this->assertFiltering('../baz.txt', 'http://example.com/baz.txt');
} }