Esempio n. 1
0
 public function testGetSingleParagraph_noSrand()
 {
     $gen = new Generator();
     for ($i = 0; $i < 1000; $i++) {
         $para = $gen->getParagraphs(1);
         $this->assertTrue($para[0] !== '', "Failed on iteration #{$i}");
     }
 }
Esempio n. 2
0
 public function testGetParagraphs()
 {
     $gen = new Generator();
     $this->assertCount(1, $gen->getParagraphs(1));
     $this->assertCount(8, $gen->getParagraphs(8));
     $this->assertCount(16, $gen->getParagraphs(16));
     $this->assertCount(64, $gen->getParagraphs(64));
     $this->assertCount(128, $gen->getParagraphs(128));
     $this->assertCount(512, $gen->getParagraphs(512));
 }