aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDhruv <dhruv.goel92@gmail.com>2014-08-10 12:55:21 +0200
committerDhruv <dhruv.goel92@gmail.com>2014-09-21 13:53:19 +0530
commitc371e86fa1a640661a47b1d4871f4ea7730f727f (patch)
treeff5c2fd2575d93e21acf85aef0bab9a980918237
parent8d0933ca4bf2724f7a67471edb6b5efe2cdc02e1 (diff)
downloadforums-c371e86fa1a640661a47b1d4871f4ea7730f727f.tar
forums-c371e86fa1a640661a47b1d4871f4ea7730f727f.tar.gz
forums-c371e86fa1a640661a47b1d4871f4ea7730f727f.tar.bz2
forums-c371e86fa1a640661a47b1d4871f4ea7730f727f.tar.xz
forums-c371e86fa1a640661a47b1d4871f4ea7730f727f.zip
[ticket/12962] Mark test skipped when phantom server not running
PHPBB3-12962
-rw-r--r--.travis.yml2
-rw-r--r--tests/test_framework/phpbb_ui_test_case.php8
2 files changed, 7 insertions, 3 deletions
diff --git a/.travis.yml b/.travis.yml
index ebe2dfe8f0..1bd16fdef7 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -34,7 +34,7 @@ install:
before_script:
- travis/setup-database.sh $DB $TRAVIS_PHP_VERSION
- - pidof phantomjs || nohup phantomjs --webserver=8910 > /dev/null
+ - pidof phantomjs || nohup phantomjs --webdriver=8910 > /dev/null
- sleep 3
script:
diff --git a/tests/test_framework/phpbb_ui_test_case.php b/tests/test_framework/phpbb_ui_test_case.php
index 271a102299..9671cc5da4 100644
--- a/tests/test_framework/phpbb_ui_test_case.php
+++ b/tests/test_framework/phpbb_ui_test_case.php
@@ -47,8 +47,12 @@ class phpbb_ui_test_case extends phpbb_test_case
if (!self::$webDriver)
{
- $capabilities = array(\WebDriverCapabilityType::BROWSER_NAME => 'firefox');
- self::$webDriver = RemoteWebDriver::create(self::$host . ':' . self::$port, $capabilities);
+ try {
+ $capabilities = array(\WebDriverCapabilityType::BROWSER_NAME => 'firefox');
+ self::$webDriver = RemoteWebDriver::create(self::$host . ':' . self::$port, $capabilities);
+ } catch (WebDriverCurlException $e) {
+ self::markTestSkipped('PhantomJS webserver is not running.');
+ }
}
if (!self::$already_installed)