From 27d37c924df614e840466be50366a96c2763caf2 Mon Sep 17 00:00:00 2001 From: Jimmy Cleuren Date: Tue, 17 Jun 2014 23:47:15 +0200 Subject: [PATCH] fixing the phpunit plugin --- PHPCI/Plugin/PhpUnit.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) mode change 100755 => 100644 PHPCI/Plugin/PhpUnit.php diff --git a/PHPCI/Plugin/PhpUnit.php b/PHPCI/Plugin/PhpUnit.php old mode 100755 new mode 100644 index 368dc474..3bb1c1c7 --- a/PHPCI/Plugin/PhpUnit.php +++ b/PHPCI/Plugin/PhpUnit.php @@ -124,7 +124,7 @@ class PhpUnit implements PHPCI\Plugin, PHPCI\ZeroConfigPlugin // Run any config files first. This can be either a single value or an array. if ($this->xmlConfigFile !== null) { - $success &= $this->runConfigFile(); + $success &= $this->runConfigFile($this->xmlConfigFile); } // Run any dirs next. Again this can be either a single value or an array. @@ -152,10 +152,10 @@ class PhpUnit implements PHPCI\Plugin, PHPCI\ZeroConfigPlugin return $success; } - protected function runConfigFile() + protected function runConfigFile($configPath) { - if (is_array($this->xmlConfigFile)) { - return $this->recurseArg($this->xmlConfigFile, array($this, "runConfigFile")); + if (is_array($configPath)) { + return $this->recurseArg($configPath, array($this, "runConfigFile")); } else { if ($this->runFrom) { $curdir = getcwd(); @@ -172,7 +172,7 @@ class PhpUnit implements PHPCI\Plugin, PHPCI\ZeroConfigPlugin $cmd = $phpunit . ' --tap %s -c "%s" ' . $this->coverage . $this->path; - $success = $this->phpci->executeCommand($cmd, $this->args, $this->phpci->buildPath . $this->xmlConfigFile); + $success = $this->phpci->executeCommand($cmd, $this->args, $this->phpci->buildPath . $configPath); if ($this->runFrom) { chdir($curdir);