Test removing some bad characters when multibyte is allowed

This commit is contained in:
Jarkko Linnanvirta 2016-01-21 12:57:50 +02:00
parent 8e4db95f72
commit cf8e9f2427

View File

@ -95,5 +95,11 @@ class URLSegmentFilterTest extends SapphireTest {
$filter = new URLSegmentFilter();
$this->assertEquals('url-has-trailing-dashes', $filter->filter('url-has-trailing-dashes--'));
}
public function testRemovesBadCharactersWithMultibyteAllowed() {
$filter = new URLSegmentFilter();
$filter->setAllowMultibyte(true);
$this->assertEquals('url-with-bad-characters', $filter->filter('url?-with/-bad#-characters='));
}
}