Пример #1
0
 public function testNl2p()
 {
     $txt1 = '';
     $txt2 = '';
     for ($i = 0; $i < 10; ++$i) {
         $txt1 .= StringFunctions::lipsum(10) . PHP_EOL;
         $txt2 .= '<p>' . StringFunctions::lipsum(10) . '</p>';
     }
     $this->assertEquals(HtmlFunctions::nl2p($txt1), $txt2);
 }
Пример #2
0
 /**
  * @expectedException \InvalidArgumentException
  */
 public function testHideEmailException()
 {
     $this->assertTrue(StringFunctions::hideEmail('this is not an email'));
 }