Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/PHPUnit/bootstrap.php6
-rw-r--r--tests/PHPUnit/phpunit.xml.dist2
-rw-r--r--tests/javascript/index.php3
3 files changed, 10 insertions, 1 deletions
diff --git a/tests/PHPUnit/bootstrap.php b/tests/PHPUnit/bootstrap.php
index 88e5362054..f74696e954 100644
--- a/tests/PHPUnit/bootstrap.php
+++ b/tests/PHPUnit/bootstrap.php
@@ -135,6 +135,7 @@ $config = Config::getInstance();
prepareServerVariables($config);
prepareTestDatabaseConfig($config);
checkPiwikSetupForTests();
+printTestDoxHint();
function checkPiwikSetupForTests()
{
@@ -156,3 +157,8 @@ Try again.";
}
}
+
+function printTestDoxHint()
+{
+ print "\nIf these tests time out consistently, it can be helpful to temporarily set testdox=true in the phpunit.xml.dist in order to see which test is causing the issue.\n";
+} \ No newline at end of file
diff --git a/tests/PHPUnit/phpunit.xml.dist b/tests/PHPUnit/phpunit.xml.dist
index 52a4a46997..0af257f09b 100644
--- a/tests/PHPUnit/phpunit.xml.dist
+++ b/tests/PHPUnit/phpunit.xml.dist
@@ -15,7 +15,7 @@
stopOnFailure="false"
stopOnIncomplete="false"
stopOnSkipped="false"
- testdox="true"
+ testdox="false"
verbose="true">
<testsuites>
diff --git a/tests/javascript/index.php b/tests/javascript/index.php
index ddec6a81e7..098809656f 100644
--- a/tests/javascript/index.php
+++ b/tests/javascript/index.php
@@ -22,7 +22,9 @@ if (!empty($_GET['plugin'])
}
try {
+ @ob_start();
$mysql = include_once $root . "/tests/PHPUnit/bootstrap.php";
+ @ob_end_clean();
} catch (Exception $e) {
echo 'alert("ERROR, not all tests are running! --> ' . $e->getMessage() . '")';
$mysql = false;
@@ -1012,6 +1014,7 @@ function PiwikTest() {
strictEqual(actual, _e('firstLink'), "findFirstNodeHavingAttributeWithValue, should find first link within body");
actual = query.findFirstNodeHavingAttributeWithValue(document.body, 'src');
+
strictEqual(actual, _e('image2'), "findFirstNodeHavingAttributeWithValue, should not return first image which has empty src attribute");