Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

run:test with --remove not creating testManifest.txt file #906

Open
nborgawkar opened this issue Sep 6, 2023 · 3 comments
Open

run:test with --remove not creating testManifest.txt file #906

nborgawkar opened this issue Sep 6, 2023 · 3 comments

Comments

@nborgawkar
Copy link

Preconditions

  1. Magento 2.4.6
  2. Magento Functional Testing Framework CLI 4.3.4
  3. PHP 8.1

Steps to reproduce

  1. sudo vendor/bin/mftf run:test AdminQuickCheckoutSalesOrderCreateTest --remove

Expected result

  1. Test should get executed successfully

Actual result

  1. Fatal error
PHP Warning:  fopen(/var/www/html/salestax/2.4.6/enterprise/dev/tests/acceptance/tests/functional/Magento/_generated/testManifest.txt): Failed to open stream: No such file or directory in /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Util/Manifest/DefaultTestManifest.php on line 68
PHP Fatal error:  Uncaught TypeError: fwrite(): Argument #1 ($stream) must be of type resource, bool given in /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Util/Manifest/DefaultTestManifest.php:93
Stack trace:
#0 /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Util/Manifest/DefaultTestManifest.php(93): fwrite()
#1 /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Util/Manifest/DefaultTestManifest.php(75): Magento\FunctionalTestingFramework\Util\Manifest\DefaultTestManifest->generateSuiteEntries()
#2 /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Console/GenerateTestsCommand.php(235): Magento\FunctionalTestingFramework\Util\Manifest\DefaultTestManifest->generate()
#3 /var/www/html/salestax/2.4.6/enterprise/vendor/symfony/console/Command/Command.php(298): Magento\FunctionalTestingFramework\Console\GenerateTestsCommand->execute()
#4 /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Console/RunTestCommand.php(133): Symfony\Component\Console\Command\Command->run()
#5 /var/www/html/salestax/2.4.6/enterprise/vendor/symfony/console/Command/Command.php(298): Magento\FunctionalTestingFramework\Console\RunTestCommand->execute()
#6 /var/www/html/salestax/2.4.6/enterprise/vendor/symfony/console/Application.php(1040): Symfony\Component\Console\Command\Command->run()
#7 /var/www/html/salestax/2.4.6/enterprise/vendor/symfony/console/Application.php(301): Symfony\Component\Console\Application->doRunCommand()
#8 /var/www/html/salestax/2.4.6/enterprise/vendor/symfony/console/Application.php(171): Symfony\Component\Console\Application->doRun()
#9 /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/bin/mftf(40): Symfony\Component\Console\Application->run()
#10 /var/www/html/salestax/2.4.6/enterprise/vendor/bin/mftf(119): include('...')
#11 {main}
  thrown in /var/www/html/salestax/2.4.6/enterprise/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Util/Manifest/DefaultTestManifest.php on line 93
@m2-assistant
Copy link

m2-assistant bot commented Sep 6, 2023

Hi @nborgawkar. 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.

@nborgawkar
Copy link
Author

Few months ago this was working fine but after this recent commit it started to create issue.
6e2dc63

SuiteGenerator::getInstance()->generateAllSuites($testManifest); function was able to create "_generated" DIR and then testManifest.txt file getting created successfully within _generated DIR but this function get moved after $testManifest->generate(); call and its started to throwing errors because _generated DIR not getting created before creating testManifest.txt file

@snez
Copy link

snez commented Oct 27, 2023

This also happens with run:group groupname -r

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants