From e7dcd82125411c54dd6c4a49a8c1fbe504507beb Mon Sep 17 00:00:00 2001 From: Pavel Pavlov Date: Wed, 26 Feb 2014 15:50:01 +0400 Subject: [PATCH 1/4] This fixes #276 : Delete Build button not functioning in view build --- PHPCI/View/Build/view.phtml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/PHPCI/View/Build/view.phtml b/PHPCI/View/Build/view.phtml index 1af884be..c06ce531 100644 --- a/PHPCI/View/Build/view.phtml +++ b/PHPCI/View/Build/view.phtml @@ -18,7 +18,7 @@ @@ -43,5 +43,13 @@ foreach ($plugins as $plugin) { From 943cb7458ae85d816786f03b1fa201e29411d10e Mon Sep 17 00:00:00 2001 From: Remo Laubacher Date: Wed, 26 Mar 2014 08:22:27 +0100 Subject: [PATCH 2/4] fix BuildLogger instantiation --- PHPCI/Builder.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PHPCI/Builder.php b/PHPCI/Builder.php index 9b88e597..b7b8c77e 100644 --- a/PHPCI/Builder.php +++ b/PHPCI/Builder.php @@ -121,7 +121,7 @@ class Builder implements LoggerAwareInterface $pluginFactory = $this->buildPluginFactory($build); $pluginFactory->addConfigFromFile(PHPCI_DIR . "/pluginconfig.php"); - $this->pluginExecutor = new Plugin\Util\Executor($pluginFactory, $this); + $this->pluginExecutor = new Plugin\Util\Executor($pluginFactory, $this->buildLogger); $this->commandExecutor = new CommandExecutor( $this->buildLogger, From 34324b494fae997b9f590ac1fab5252a79a418ed Mon Sep 17 00:00:00 2001 From: zigster Date: Sun, 30 Mar 2014 11:59:56 +0200 Subject: [PATCH 3/4] Bugfix Errors with PHPCI GitHub hook #296 > fixed access to undefined class member _buildStore to buildStore --- PHPCI/Controller/WebhookController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PHPCI/Controller/WebhookController.php b/PHPCI/Controller/WebhookController.php index 1b118440..9a9d143b 100644 --- a/PHPCI/Controller/WebhookController.php +++ b/PHPCI/Controller/WebhookController.php @@ -97,7 +97,7 @@ class WebhookController extends \PHPCI\Controller } try { - $this->_buildStore->save($build); + $this->buildStore->save($build); /** bugfix: Errors with PHPCI GitHub hook #296 */ } catch (\Exception $ex) { header('HTTP/1.1 500 Internal Server Error'); header('Ex: ' . $ex->getMessage()); From 9d655c0559d4de5594da136871a70afa00a3e4f3 Mon Sep 17 00:00:00 2001 From: Witold Wasiczko Date: Mon, 24 Mar 2014 16:55:42 +0100 Subject: [PATCH 4/4] Use args in Codeception plugin --- PHPCI/Plugin/Codeception.php | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/PHPCI/Plugin/Codeception.php b/PHPCI/Plugin/Codeception.php index 802d3540..bac0e7be 100644 --- a/PHPCI/Plugin/Codeception.php +++ b/PHPCI/Plugin/Codeception.php @@ -20,7 +20,14 @@ use PHPCI\Model\Build; */ class Codeception implements \PHPCI\Plugin { - protected $args; + /** + * @var string + */ + protected $args = ''; + + /** + * @var Builder + */ protected $phpci; /** @@ -30,14 +37,13 @@ class Codeception implements \PHPCI\Plugin public function __construct(Builder $phpci, Build $build, array $options = array()) { - $this->phpci = $phpci; + $this->phpci = $phpci; if (isset($options['config'])) { $this->xmlConfigFile = $options['config']; } - if (isset($options['args'])) { - $this->args = $options['args']; + $this->args = (string) $options['args']; } } @@ -69,9 +75,9 @@ class Codeception implements \PHPCI\Plugin return false; } - $cmd = 'cd "%s" && ' . $codecept . ' run -c "%s"'; + $cmd = 'cd "%s" && ' . $codecept . ' run -c "%s" '. $this->args; if (IS_WIN) { - $cmd = 'cd /d "%s" && ' . $codecept . ' run -c "%s"'; + $cmd = 'cd /d "%s" && ' . $codecept . ' run -c "%s" '. $this->args; } $success = $this->phpci->executeCommand($cmd, $this->phpci->buildPath, $this->phpci->buildPath . $configPath);