You are here

public function BuildTestTest::testCopyCodebase in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/BuildTests/Framework/Tests/BuildTestTest.php \Drupal\BuildTests\Framework\Tests\BuildTestTest::testCopyCodebase()
  2. 9 core/tests/Drupal/BuildTests/Framework/Tests/BuildTestTest.php \Drupal\BuildTests\Framework\Tests\BuildTestTest::testCopyCodebase()

@covers ::copyCodebase

File

core/tests/Drupal/BuildTests/Framework/Tests/BuildTestTest.php, line 37

Class

BuildTestTest
@coversDefaultClass \Drupal\BuildTests\Framework\BuildTestBase @group Build

Namespace

Drupal\BuildTests\Framework\Tests

Code

public function testCopyCodebase() {
  $test_directory = 'copied_codebase';
  $this
    ->copyCodebase(NULL, $test_directory);
  $full_path = $this
    ->getWorkspaceDirectory() . '/' . $test_directory;
  $files = [
    'autoload.php',
    'composer.json',
    'index.php',
    'README.md',
    '.git',
    '.ht.router.php',
  ];
  foreach ($files as $file) {
    $this
      ->assertFileExists($full_path . '/' . $file);
  }
}