public function testFailure()
 {
     $command = new Command();
     $command->exec("ls a/path/that/hopefully/doesnt/exist/if/it/does/craziness");
     $this->assertTrue($command->failure());
 }
Example #2
0
 private function createLocalFile($name, $contents = "")
 {
     $command = new Local\Command();
     $filePath = $this->getLocalPath($name);
     $command->exec("echo -n " . escapeshellarg($contents) . " >" . escapeshellarg($filePath));
     if ($command->failure()) {
         $this->markTestSkipped("Could not create local file.");
     }
     return $filePath;
 }