Example #1
0
 public function testOptionsAreCorrectlySavedIfItIsLocalOrRemoteContent()
 {
     $testObject = new PdfSpy();
     $testObject->setTemporaryFolder(__DIR__);
     $testObject->getOutputFromHtml('<html></html>', array('footer-html' => 'footer', 'xsl-style-sheet' => 'http://google.com'));
     $this->assertRegExp("/emptyBinary --lowquality --footer-html '.*.html' --xsl-style-sheet '.*.xsl' '.*.html' '.*.pdf'/", $testObject->getLastCommand());
 }
Example #2
0
 /**
  * @expectedException PHPUnit_Framework_Error
  */
 public function testThatSomethingUsingWrongTmpFolder()
 {
     $testObject = new PdfSpy();
     $testObject->setTemporaryFolder(__DIR__ . '/i-dont-exist');
     $testObject->getOutputFromHtml('<html></html>', array('footer-html' => 'footer'));
 }