aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleg Pudeyev <oleg@bsdpower.com>2011-11-24 03:26:51 -0500
committerOleg Pudeyev <oleg@bsdpower.com>2011-11-24 14:03:09 -0500
commit44cab5696fb7cb60a97f4010c3ef75f88d879b6a (patch)
tree4cd1956db180d76761298d5c30669ce87f2df5d1
parent3d17816812445e660ce32424115bd1efda0343d4 (diff)
downloadforums-44cab5696fb7cb60a97f4010c3ef75f88d879b6a.tar
forums-44cab5696fb7cb60a97f4010c3ef75f88d879b6a.tar.gz
forums-44cab5696fb7cb60a97f4010c3ef75f88d879b6a.tar.bz2
forums-44cab5696fb7cb60a97f4010c3ef75f88d879b6a.tar.xz
forums-44cab5696fb7cb60a97f4010c3ef75f88d879b6a.zip
[ticket/10481] Skip functional tests if phar extension is missing.
PHPBB3-10481
-rw-r--r--tests/test_framework/phpbb_functional_test_case.php11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/test_framework/phpbb_functional_test_case.php b/tests/test_framework/phpbb_functional_test_case.php
index 18bf2a84a8..57cc0f8959 100644
--- a/tests/test_framework/phpbb_functional_test_case.php
+++ b/tests/test_framework/phpbb_functional_test_case.php
@@ -7,7 +7,6 @@
*
*/
-require_once __DIR__ . '/../../vendor/goutte.phar';
require_once __DIR__ . '/../../phpBB/includes/functions_install.php';
class phpbb_functional_test_case extends phpbb_test_case
@@ -18,6 +17,16 @@ class phpbb_functional_test_case extends phpbb_test_case
static protected $config = array();
static protected $already_installed = false;
+ static public function setUpBeforeClass()
+ {
+ if (!extension_loaded('phar'))
+ {
+ self::markTestSkipped('phar extension is not loaded');
+ }
+
+ require_once __DIR__ . '/../../vendor/goutte.phar';
+ }
+
public function setUp()
{
if (!isset(self::$config['phpbb_functional_url']))