mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
MINOR Isolating testRaw2URL settings
This commit is contained in:
parent
8281678d4c
commit
41b51a17ce
@ -116,10 +116,13 @@ class ConvertTest extends SapphireTest {
|
|||||||
* @todo test toASCII()
|
* @todo test toASCII()
|
||||||
*/
|
*/
|
||||||
function testRaw2URL() {
|
function testRaw2URL() {
|
||||||
|
$orig = URLSegmentFilter::$default_allow_multibyte;
|
||||||
|
URLSegmentFilter::$default_allow_multibyte = false;
|
||||||
$this->assertEquals('foo', Convert::raw2url('foo'));
|
$this->assertEquals('foo', Convert::raw2url('foo'));
|
||||||
$this->assertEquals('foo-and-bar', Convert::raw2url('foo & bar'));
|
$this->assertEquals('foo-and-bar', Convert::raw2url('foo & bar'));
|
||||||
$this->assertEquals('foo-and-bar', Convert::raw2url('foo & bar!'));
|
$this->assertEquals('foo-and-bar', Convert::raw2url('foo & bar!'));
|
||||||
$this->assertEquals('foos-bar-2', Convert::raw2url('foo\'s [bar] (2)'));
|
$this->assertEquals('foos-bar-2', Convert::raw2url('foo\'s [bar] (2)'));
|
||||||
|
URLSegmentFilter::$default_allow_multibyte = $orig;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user