![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/cartforge.co/dev/tests/setup-integration/framework/ |
<?php /** * Copyright © Magento, Inc. All rights reserved. * See COPYING.txt for license details. */ /** * @var $testFrameworkDir string - Must be defined in parent script. */ /** * Copy test modules to app/code/Magento to make them visible for Magento instance. */ $pathToCommittedTestModules = $testFrameworkDir . '/../_files/Magento'; $pathToInstalledMagentoInstanceModules = $testFrameworkDir . '/../../../../app/code/Magento'; $iterator = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($pathToCommittedTestModules, RecursiveDirectoryIterator::FOLLOW_SYMLINKS) ); //collect test modules dirs name $testModuleNames = array_diff(scandir($pathToCommittedTestModules), ['..', '.']); //remove test modules from magento codebase foreach ($testModuleNames as $name) { $folder = $pathToInstalledMagentoInstanceModules . '/' . $name; if (is_dir($folder)) { \Magento\Framework\Filesystem\Io\File::rmdirRecursive($folder); } }