コード例 #1
0
 public function runTest()
 {
     $stdout = PHPUnit_Extensions_Phantom_Driver::executePhantomJS($this->file[0]);
     $this->assertNotEmpty($stdout);
     // return the test result for further assertions
     return $stdout;
 }
コード例 #2
0
 public function testExecutePhantomJs()
 {
     $testFile = TESTS_DIR . '/PhantomJS-examples/version.js';
     $result = PHPUnit_Extensions_Phantom_Driver::executePhantomJS($testFile);
     $this->assertContains('using PhantomJS version ', $result);
 }