function BuildTestTest::testCopyCodebase

Same name in other branches
  1. 8.9.x core/tests/Drupal/BuildTests/Framework/Tests/BuildTestTest.php \Drupal\BuildTests\Framework\Tests\BuildTestTest::testCopyCodebase()
  2. 10 core/tests/Drupal/BuildTests/Framework/Tests/BuildTestTest.php \Drupal\BuildTests\Framework\Tests\BuildTestTest::testCopyCodebase()
  3. 11.x 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);
    }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.