Esempio n. 1
0
 public function __construct($config, $options)
 {
     if (!empty($config['files'])) {
         array_walk($config['files'], [$this, 'ensureSource']);
         array_walk($config['files'], [$this, 'ensureDestination']);
     }
     parent::__construct($config, $options);
 }
 /**
  * @param $config
  * @param $options
  */
 function __construct($config, $options)
 {
     if (empty($this->config['templateFolder'])) {
         $this->config['templateFolder'] = __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'Templates';
     }
     $this->config['templateFolder'] = rtrim($this->config['templateFolder'], DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
     parent::__construct($config, $options);
 }
 /**
  * Class constructor.
  *
  * @param array              $config
  * @param array              $options
  * @param PhireMockProcess   $process  optional PhiremockProcess object
  */
 public function __construct(array $config, array $options, PhiremockProcess $process = null)
 {
     $this->config['bin_path'] = Config::projectDir() . '../vendor/bin/phiremock';
     $this->config['logs_path'] = Config::logDir();
     parent::__construct($config, $options);
     $this->initProcess($process);
     list($ip, $port) = explode(':', $this->config['listen']);
     $this->process->start($ip, $port, $this->config['bin_path'], $this->config['logs_path'], $this->config['debug']);
     if ($this->config['startDelay']) {
         sleep($this->config['startDelay']);
     }
 }
Esempio n. 4
0
 public function __construct($config, $options, Filesystem $filesystem = null)
 {
     $this->filesystem = $filesystem ? $filesystem : new Filesystem();
     parent::__construct($config, $options);
 }