-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Closed
Labels
Fixed in 2.3.xThe issue has been fixed in 2.3 release lineThe issue has been fixed in 2.3 release lineIssue: Cannot ReproduceCannot reproduce the issue on the latest `2.4-develop` branchCannot reproduce the issue on the latest `2.4-develop` branchIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedGate 2 Passed. Manual verification of the issue description passedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedGate 1 Passed. Automatic verification of issue format passed
Description
I have freshly installed Magento 2.2. The first thing I do is running unit tests. I have got one error.
Preconditions
- Magento 2.2
- PHP 7.0
- MySQL 5.7.19, for Linux (x86_64)
Steps to reproduce
- Install Magento with composer
- Run this command
vendor/bin/phpunit -c dev/tests/unit/phpunit.xml.dist - You get the error
Expected result
- To pass all the unit tests
Actual result
- You got the following error:
Magento\Setup\Test\Unit\Module\Di\Code\Reader\FileClassScannerTest::testClassKeywordInMiddleOfFile
Magento\Setup\Module\Di\Code\Reader\InvalidFileException: The file "/var/www/html/magento2-install1" does not exist or is not a file
/var/www/html/magento2-install1/setup/src/Magento/Setup/Module/Di/Code/Reader/FileClassScanner.php:39
/var/www/html/magento2-install1/setup/src/Magento/Setup/Test/Unit/Module/Di/Code/Reader/FileClassScannerTest.php:213
When I look at this file setup/src/Magento/Setup/Test/Unit/Module/Di/Code/Reader/FileClassScannerTest.php, I am seeing the following test.
public function testClassKeywordInMiddleOfFile()
{
$filename = __DIR__
. '/../../../../../../../../../..'
. '/app/code/Magento/Catalog/Model/ResourceModel/Product/Indexer/Eav/AbstractEav.php';
$filename = realpath($filename);
$scanner = new FileClassScanner($filename);
$result = $scanner->getClassNames();
self::assertCount(1, $result);
}This is interesting that there is not any file in app/code, since the file it is looking for inside vendor directory.
wexo-team
Metadata
Metadata
Assignees
Labels
Fixed in 2.3.xThe issue has been fixed in 2.3 release lineThe issue has been fixed in 2.3 release lineIssue: Cannot ReproduceCannot reproduce the issue on the latest `2.4-develop` branchCannot reproduce the issue on the latest `2.4-develop` branchIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedGate 2 Passed. Manual verification of the issue description passedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedGate 1 Passed. Automatic verification of issue format passed