Browse Source

Fix issue with trim line ending and test content.

euromark 11 years ago
parent
commit
8b0567b26d
1 changed files with 6 additions and 8 deletions
  1. 6 8
      tests/TestCase/Utility/TextTest.php

+ 6 - 8
tests/TestCase/Utility/TextTest.php

@@ -423,14 +423,12 @@ TEXT;
         $this->assertTextEquals($expected, $result, 'Text not wrapped.');
         $this->assertTextEquals($expected, $result, 'Text not wrapped.');
 
 
         $result = Text::wrap($text, ['width' => 20, 'wordWrap' => false]);
         $result = Text::wrap($text, ['width' => 20, 'wordWrap' => false]);
-        $expected = <<<TEXT
-This is the song th
-at never ends. This
- is the song that n
-ever ends. This is
-the song that never
- ends.
-TEXT;
+        $expected = 'This is the song th' . "\n" .
+            'at never ends. This' . "\n" .
+            ' is the song that n' . "\n" .
+            'ever ends. This is ' . "\n" .
+            'the song that never' . "\n" .
+            ' ends.';
         $this->assertTextEquals($expected, $result, 'Text not wrapped.');
         $this->assertTextEquals($expected, $result, 'Text not wrapped.');
     }
     }