Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #520 from dogmatic69/2610

Closes #2610
  • Loading branch information...
commit 3a391529d27ccd2361821b9aa91014973923362c 2 parents 1ddc8f6 + 2787052
@markstory markstory authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  lib/Cake/Test/Case/Utility/StringTest.php
View
2  lib/Cake/Test/Case/Utility/StringTest.php
@@ -370,6 +370,7 @@ public function testTruncate() {
$text7 = 'El moño está en el lugar correcto. Eso fue lo que dijo la niña, ¿habrá dicho la verdad?';
$text8 = 'Vive la R' . chr(195) . chr(169) . 'publique de France';
$text9 = 'НОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыь';
+ $text10 = 'http://example.com/something/foo:bar';
$this->assertSame($this->Text->truncate($text1, 15), 'The quick br...');
$this->assertSame($this->Text->truncate($text1, 15, array('exact' => false)), 'The quick...');
@@ -394,6 +395,7 @@ public function testTruncate() {
$this->assertSame($this->Text->truncate($text7, 15), 'El moño está...');
$this->assertSame($this->Text->truncate($text8, 15), 'Vive la R'.chr(195).chr(169).'pu...');
$this->assertSame($this->Text->truncate($text9, 10), 'НОПРСТУ...');
+ $this->assertSame($this->Text->truncate($text10, 30), 'http://example.com/somethin...');
$text = '<p><span style="font-size: medium;"><a>Iamatestwithnospacesandhtml</a></span></p>';
$result = $this->Text->truncate($text, 10, array(
Please sign in to comment.
Something went wrong with that request. Please try again.