|
18 | 18 | $logWriter->setFormatter(new \Zend_Log_Formatter_Simple('%message%' . PHP_EOL));
|
19 | 19 | $logger = new \Zend_Log($logWriter);
|
20 | 20 |
|
21 |
| -/** Copy test modules to app/code/Magento to make them visible for Magento instance */ |
22 |
| -$pathToCommittedTestModules = __DIR__ . '/../_files/Magento'; |
23 |
| -$pathToInstalledMagentoInstanceModules = __DIR__ . '/../../../../app/code/Magento'; |
24 |
| -$iterator = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($pathToCommittedTestModules)); |
25 |
| -/** @var SplFileInfo $file */ |
26 |
| -foreach ($iterator as $file) { |
27 |
| - if (!$file->isDir()) { |
28 |
| - $source = $file->getPathname(); |
29 |
| - $relativePath = substr($source, strlen($pathToCommittedTestModules)); |
30 |
| - $destination = $pathToInstalledMagentoInstanceModules . $relativePath; |
31 |
| - $targetDir = dirname($destination); |
32 |
| - if (!is_dir($targetDir)) { |
33 |
| - mkdir($targetDir, 0755, true); |
34 |
| - } |
35 |
| - copy($source, $destination); |
36 |
| - } |
37 |
| -} |
38 |
| -unset($iterator, $file); |
39 |
| - |
40 |
| -// Register the modules under '_files/' |
41 |
| -$pathPattern = $pathToInstalledMagentoInstanceModules . '/TestModule*/registration.php'; |
42 |
| -$files = glob($pathPattern, GLOB_NOSORT); |
43 |
| -if ($files === false) { |
44 |
| - throw new \RuntimeException('glob() returned error while searching in \'' . $pathPattern . '\''); |
45 |
| -} |
46 |
| -foreach ($files as $file) { |
47 |
| - include $file; |
48 |
| -} |
| 21 | +require_once __DIR__ . '/../../integration/framework/deployFixture.php'; |
49 | 22 |
|
50 | 23 | /* Bootstrap the application */
|
51 | 24 | $settings = new \Magento\TestFramework\Bootstrap\Settings($testsBaseDir, get_defined_constants());
|
|
0 commit comments