Ejemplo n.º 1
0
 protected function _getCmd()
 {
     $bootstrapfile = $this->_runner->getConfig('testsBootstrapFile', '');
     $bootstrapfileparam = empty($bootstrapfile) ? '' : ' --bootstrap ' . escapeshellarg($bootstrapfile);
     $phpunitcmd = $this->_runner->getEnvironment()->getHelper('php')->getPhpUnit();
     $cmd = $phpunitcmd . ' --log-junit ' . escapeshellarg($this->_tmpXmlPath) . $bootstrapfileparam . ' ' . escapeshellarg($this->_classname) . ' ' . escapeshellarg($this->_filename) . ' 2>&1';
     return $cmd;
 }
Ejemplo n.º 2
0
 public function getBin($execName)
 {
     $vendorDir = $this->_runner->getConfig('vendorDir', '');
     if (!empty($vendorDir) && file_exists($vendorDir . '/bin/' . $execName)) {
         return $vendorDir . '/bin/' . $execName;
     } else {
         $toolsDir = $this->_runner->getConfig('toolsDir', '');
         if (!empty($toolsDir) && file_exists($toolsDir . '/' . $execName)) {
             return $toolsDir . '/' . $execName;
         } else {
             return $execName;
         }
     }
 }
Ejemplo n.º 3
0
 public function log($str)
 {
     // hide sensitive values
     $hideKeys = array('password', 'secret', 'login');
     $hideKeys = array_merge($hideKeys, $this->_runner->getConfig('hideConfigKeys', array()));
     foreach ($hideKeys as $k) {
         foreach ($this->_runner->getConfig() as $ck => $cv) {
             if (strpos(strtolower($ck), strtolower($k)) !== false) {
                 if (!empty($cv)) {
                     $str = str_replace($cv, '*****', $str);
                 }
             }
         }
     }
     echo $str . "\n";
     return true;
 }
Ejemplo n.º 4
0
 public function getOutputPath()
 {
     return $this->_runner->getConfig('outputPath') . '/' . $this->_integid;
 }