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
diff options
context:
space:
mode:
Diffstat (limited to 'tests/PHPUnit/System/ConsoleTest.php')
-rw-r--r--tests/PHPUnit/System/ConsoleTest.php13
1 files changed, 10 insertions, 3 deletions
diff --git a/tests/PHPUnit/System/ConsoleTest.php b/tests/PHPUnit/System/ConsoleTest.php
index 1fd9d8330d..a82d31ecfb 100644
--- a/tests/PHPUnit/System/ConsoleTest.php
+++ b/tests/PHPUnit/System/ConsoleTest.php
@@ -106,7 +106,7 @@ class TestCommandWithException extends ConsoleCommand
}
/**
- * @group ConsoleTest3
+ * @group ConsoleTest
*/
class ConsoleTest extends ConsoleCommandTestCase
{
@@ -166,7 +166,6 @@ class ConsoleTest extends ConsoleCommandTestCase
$output = $this->normalizeOutput($output);
$expected = <<<END
-#!/usr/bin/env php
PHP Fatal error: Allowed memory size of X bytes exhausted (tried to allocate X bytes) in /tests/PHPUnit/System/ConsoleTest.php on line 85
Fatal error: Allowed memory size of X bytes exhausted (tried to allocate X bytes) in /tests/PHPUnit/System/ConsoleTest.php on line 85
@@ -183,6 +182,10 @@ Matomo encountered an error: Allowed memory size of X bytes exhausted (tried to
))
END;
+ if (PHP_MAJOR_VERSION < 8) {
+ $expected = "#!/usr/bin/env php\n" . $expected;
+ }
+
$this->assertEquals($expected, $output);
}
@@ -196,7 +199,6 @@ END;
$output = $this->normalizeOutput($output);
$expected = <<<END
-#!/usr/bin/env php
*** IN SAFEMODE ***
@@ -211,6 +213,11 @@ test-command-with-exception
END;
+
+ if (PHP_MAJOR_VERSION < 8) {
+ $expected = "#!/usr/bin/env php\n" . $expected;
+ }
+
$this->assertEquals($expected, $output);
}