mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
add test for backslash on Convert::raw2htmlid
This commit is contained in:
parent
d52e972453
commit
4d098fc2ad
@ -195,11 +195,14 @@ PHP
|
||||
$val1 = 'test test 123';
|
||||
$this->assertEquals('test_test_123', Convert::raw2htmlid($val1));
|
||||
|
||||
$val1 = 'test[test][123]';
|
||||
$this->assertEquals('test_test_123', Convert::raw2htmlid($val1));
|
||||
$val2 = 'test[test][123]';
|
||||
$this->assertEquals('test_test_123', Convert::raw2htmlid($val2));
|
||||
|
||||
$val1 = '[test[[test]][123]]';
|
||||
$this->assertEquals('test_test_123', Convert::raw2htmlid($val1));
|
||||
$val3 = '[test[[test]][123]]';
|
||||
$this->assertEquals('test_test_123', Convert::raw2htmlid($val3));
|
||||
|
||||
$val4 = 'A\\Namespaced\\Class';
|
||||
$this->assertEquals('A_Namespaced_Class', Convert::raw2htmlid($val4));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user