From 46f42ceb73d887f6feb6cbe861cee90e0a7f42aa Mon Sep 17 00:00:00 2001 From: kshitij sharma Date: Fri, 30 Oct 2015 11:27:28 +0100 Subject: [PATCH 1/3] Kill selenium Server Function to kill the already running selenium server --- RoboFile.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/RoboFile.php b/RoboFile.php index 02dfb6a..7b12979 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -211,4 +211,16 @@ class RoboFile extends \Robo\Tasks $this->_exec('curl --retry 3 --retry-delay 5 -sS https://getcomposer.org/installer | php'); } } + + /** + * Kills the selenium server running + * + * @param string $host Web host of the remote server. + * @param string $port Server port. + */ + public function killSelenium($host = 'localhost', $port = '4444') + { + $this->say('Trying to kill the selenium server.'); + $this->_exec("curl http://$host:$port/selenium-server/driver/?cmd=shutDownSeleniumServer"); + } } From 6bacebcaff5e92f0b83de6b6e7673c4c71c17108 Mon Sep 17 00:00:00 2001 From: kshitij sharma Date: Fri, 30 Oct 2015 14:32:55 +0100 Subject: [PATCH 2/3] Update RoboFile.php --- RoboFile.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/RoboFile.php b/RoboFile.php index 7b12979..1bdea27 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -150,9 +150,6 @@ class RoboFile extends \Robo\Tasks ->arg('--debug') ->run() ->stopOnFail(); - - // Kill selenium server - // $this->_exec('curl http://localhost:4444/selenium-server/driver/?cmd=shutDownSeleniumServer'); } /** From 577933c5f8b1ddfde6590c4f4b80bcdebd1975d8 Mon Sep 17 00:00:00 2001 From: kshitij sharma Date: Fri, 30 Oct 2015 14:33:23 +0100 Subject: [PATCH 3/3] Update RoboFile.php --- RoboFile.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/RoboFile.php b/RoboFile.php index 1bdea27..883e858 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -75,10 +75,6 @@ class RoboFile extends \Robo\Tasks ->arg('tests/acceptance/frontend/') ->run() ->stopOnFail(); - - // Kill selenium server - // $this->_exec('curl http://localhost:4444/selenium-server/driver/?cmd=shutDownSeleniumServer'); - /* // Uncomment this lines if you need to debug selenium errors $seleniumErrors = file_get_contents('selenium.log');