Skip to content

Commit 6d6a7c5

Browse files
committed
MQE-2391: [GitHub Issue] Magento fails with xdebug 3 due to mftf
1 parent e95fb10 commit 6d6a7c5

File tree

3 files changed

+4
-13
lines changed

3 files changed

+4
-13
lines changed

dev/tests/functional/standalone_bootstrap.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,3 @@
7070

7171
$RELATIVE_TESTS_MODULE_PATH = '/tests/functional/tests/MFTF';
7272
defined('TESTS_MODULE_PATH') || define('TESTS_MODULE_PATH', realpath(TESTS_BP . $RELATIVE_TESTS_MODULE_PATH));
73-
74-
75-
// add the debug flag here
76-
$debug_mode = $_ENV['MFTF_DEBUG'] ?? false;

src/Magento/FunctionalTestingFramework/Config/MftfApplicationConfig.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -100,17 +100,15 @@ private function __construct(
100100

101101
$this->phase = $phase;
102102
$this->verboseEnabled = $verboseEnabled;
103-
if (isset($debugLevel) && !in_array(strtolower($debugLevel), self::MFTF_DEBUG_LEVEL)) {
103+
if (!in_array(strtolower($debugLevel), self::MFTF_DEBUG_LEVEL)) {
104104
throw new TestFrameworkException("{$debugLevel} is not a debug level. Use 'DEFAULT' or 'DEVELOPER'");
105105
}
106106
switch (strtolower($debugLevel)) {
107-
case self::LEVEL_DEVELOPER:
108107
case self::LEVEL_DEFAULT:
109-
$this->debugLevel = $debugLevel;
108+
$this->debugLevel = self::LEVEL_DEFAULT;
110109
break;
111-
case null:
110+
default:
112111
$this->debugLevel = self::LEVEL_DEVELOPER;
113-
break;
114112
}
115113
$this->allowSkipped = $allowSkipped;
116114
$this->filterList = new FilterList($filters);
@@ -196,7 +194,7 @@ public function verboseEnabled()
196194
*/
197195
public function getDebugLevel()
198196
{
199-
return $this->debugLevel ?? getenv('MFTF_DEBUG');
197+
return $this->debugLevel;
200198
}
201199

202200
/**

src/Magento/FunctionalTestingFramework/_bootstrap.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,3 @@
7474
'TESTS_MODULE_PATH',
7575
realpath(TESTS_BP . $RELATIVE_TESTS_MODULE_PATH)
7676
);
77-
78-
// add the debug flag here
79-
$debugMode = $_ENV['MFTF_DEBUG'] ?? false;

0 commit comments

Comments
 (0)