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);
 }
Esempio n. 3
0
 public static function getSubscribedEvents()
 {
     $inheritedEvents = parent::getSubscribedEvents();
     $events = [];
     if (static::$group) {
         $events = [Events::TEST_BEFORE . '.' . static::$group => '_before', Events::TEST_AFTER . '.' . static::$group => '_after'];
     }
     return array_merge($events, $inheritedEvents);
 }
 /**
  * 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. 5
0
 public function _initialize()
 {
     parent::_initialize();
     $this->checkRequirements();
 }