Example #1
0
 /**
  * Tests File::getExecutable
  */
 public function testDefault()
 {
     $path = $this->getBinDir();
     $dir = new File(__FILE__, $path);
     $target = $this->getTargetMock(__FILE__, __FILE__ . '.gz');
     $target->method('getCompressor')->willReturn($this->getCompressorMock('gzip', 'gz'));
     $executable = $dir->getExecutable($target);
     $cmd = $executable->getCommandLine();
     $this->assertEquals($path . '/gzip -f \'' . __FILE__ . '\' 2> /dev/null', $cmd);
 }