Inheritance: extends PHPUnit_Framework_TestCase
 protected function setUp()
 {
     parent::setUp();
     $this->homedir = $this->getNewTmpFolder('gush-home');
     putenv('GUSH_HOME=' . $this->homedir);
     putenv('GUSH_CACHE_DIR');
 }
Exemple #2
0
 public function setUp()
 {
     parent::setUp();
     $this->template = $this->prophesize(TemplateInterface::class);
     $inputDef = new InputDefinition();
     $inputDef->addOption(new InputOption('test-option', null, InputOption::VALUE_OPTIONAL));
     $this->input = new ArrayInput(['--test-option' => null], $inputDef);
     $this->output = new BufferedOutput();
     $this->application = $this->getApplication();
     $styleHelper = $this->application->getHelperSet()->get('gush_style');
     $styleHelper->setInput($this->input);
     $styleHelper->setOutput($this->output);
     $this->helper = new TemplateHelper($styleHelper, $this->application);
     $this->helper->setInput($this->input);
 }
Exemple #3
0
 protected function setUp()
 {
     parent::setUp();
     $this->homedir = $this->getNewTmpDirectory('home');
 }
 protected function getGitConfigHelper($hasRemote = true)
 {
     $helper = parent::getGitConfigHelper();
     $helper->getRemoteInfo('origin')->willReturn(['host' => 'github.com', 'vendor' => 'gushphp', 'repo' => 'gush']);
     $helper->remoteExists('cordoval')->willReturn(false);
     $helper->remoteExists('origin')->willReturn($hasRemote);
     $helper->getGitConfig('remote.origin.url')->willReturn('git@github.com:gushphp/gush.git');
     return $helper;
 }
Exemple #5
0
 protected function setUp()
 {
     parent::setUp();
     $this->homedir = $this->getNewTmpFolder('home');
 }