Skip to content

Commit 4651c9c

Browse files
committed
MQE-1040: MFTF standalone commands do not pass down constants correctly
- Corrected original ticket - Changed functional run location from alternate Magento Directory to project directory whether standalone or in vendor
1 parent 66b6ecd commit 4651c9c

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

dev/tests/functional/standalone_bootstrap.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
if (array_key_exists('MAGENTO_BP', $_ENV)) {
2929
// TODO REMOVE THIS CODE ONCE WE HAVE STOPPED SUPPORTING dev/tests/acceptance PATH
3030
// define TEST_PATH and TEST_MODULE_PATH
31-
defined('TESTS_BP') || define('TESTS_BP', realpath(MAGENTO_BP . DIRECTORY_SEPARATOR . 'dev/tests/acceptance/'));
32-
33-
$RELATIVE_TESTS_MODULE_PATH = '/tests/functional/Magento/FunctionalTest';
31+
// defined('TESTS_BP') || define('TESTS_BP', realpath(MAGENTO_BP . DIRECTORY_SEPARATOR . 'dev/tests/acceptance/'));
32+
defined('TESTS_BP') || define('TESTS_BP', dirname(dirname(__DIR__)));
33+
$RELATIVE_TESTS_MODULE_PATH = '/tests/functional/tests/MFTF';
3434
defined('TESTS_MODULE_PATH') || define(
3535
'TESTS_MODULE_PATH',
3636
realpath(TESTS_BP . $RELATIVE_TESTS_MODULE_PATH)

src/Magento/FunctionalTestingFramework/_bootstrap.php

+4
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@
3232
defined($key) || define($key, $var);
3333
}
3434

35+
if (array_key_exists('MAGENTO_BP', $_ENV)) {
36+
defined('TESTS_BP') || define('TESTS_BP', realpath(PROJECT_ROOT . DIRECTORY_SEPARATOR . 'dev/tests/acceptance'));
37+
}
38+
3539
defined('MAGENTO_CLI_COMMAND_PATH') || define(
3640
'MAGENTO_CLI_COMMAND_PATH',
3741
'dev/tests/acceptance/utils/command.php'

0 commit comments

Comments
 (0)