magento / magento2-functional-testing-framework

Magento2 Functional Testing Framework
Other
155 stars 133 forks source link

Helpers Autoload Issue - Class `Group\AppConfigDumpSuite` is not defined. Autoload it or include into '_bootstrap.php' file of 'tests' directory #918

Open Nurgiel opened 4 months ago

Nurgiel commented 4 months ago

Preconditions

  1. PHP8.2
  2. latest MFTF Standalone (4.7.2) in /home/kali/mftf
  3. unmodified Magento 2.4.7 in /var/www/html/magento2test

Hello, I'm getting errors like:

[Magento\FunctionalTestingFramework\Exceptions\TestFrameworkException]
Make sure cest files are generated before running bin/mftf codecept:run
Class `Group\AppConfigDumpSuite` is not defined. Autoload it or include into '_bootstrap.php' file of 'tests' directory

Exception trace:
at /home/kali/mftf/src/Magento/FunctionalTestingFramework/Console/CodeceptRunCommand.php:50
Magento\FunctionalTestingFramework\Console\CodeceptRunCommand->execute() at /home/kali/mftf/vendor/symfony/console/Command/Command.php:326

whenever I run a test that uses a custom helper.

I can run any tests that don't use Helpers.

My /home/kali/mftf/dev/.env looks like:

MAGENTO_BASE_URL=https://magento2test.com/
MAGENTO_BACKEND_NAME=admin
MAGENTO_ADMIN_USERNAME=admin
SELENIUM_CLOSE_ALL_SESSIONS=true
BROWSER=chrome
WINDOW_WIDTH=1920
WINDOW_HEIGHT=1080
MODULE_ALLOWLIST=Magento_Framework,ConfigurableProductWishlist,ConfigurableProductCatalogSearch
WAIT_TIMEOUT=60
MAGENTO_CLI_WAIT_TIMEOUT=60
BROWSER_LOG_BLOCKLIST=other
ELASTICSEARCH_VERSION=7
MAGENTO_BP=/var/www/html/magento2test
ENABLE_PAUSE=true

I can see /var/www/html/magento2test/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Group/AppConfigDumpSuite.php was generated in the magento2test project vendor folder.

When I search for "AppConfigDump" it in ~/mftf then I see what's on the screenshot below.

image

image

Any ideas how can I fix this autoload issue?

m2-assistant[bot] commented 4 months ago

Hi @Nurgiel. Thank you for your report. To speed up processing of this issue, make sure that you provided sufficient information. Add a comment to assign the issue: @magento I am working on this


Join Magento Community Engineering Slack and ask your questions in #github channel.