mirror of
https://github.com/moodle/moodle.git
synced 2025-08-08 02:16:41 +02:00
Merge branch 'MDL-40877-master' of git://github.com/FMCorz/moodle
This commit is contained in:
commit
92058753ac
3 changed files with 62 additions and 15 deletions
|
@ -360,5 +360,16 @@ class core_text_testcase extends advanced_testcase {
|
|||
$this->assertSame($textlib->specialtoascii('ábc'), 'abc');
|
||||
$this->assertSame($textlib->strtotitle('abc ABC'), 'Abc Abc');
|
||||
}
|
||||
|
||||
/**
|
||||
* Test strrchr.
|
||||
*/
|
||||
public function test_strrchr() {
|
||||
$str = "Žluťoučký koníček";
|
||||
$this->assertSame('koníček', core_text::strrchr($str, 'koní'));
|
||||
$this->assertSame('Žluťoučký ', core_text::strrchr($str, 'koní', true));
|
||||
$this->assertFalse(core_text::strrchr($str, 'A'));
|
||||
$this->assertFalse(core_text::strrchr($str, 'ç', true));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue