function InstallerConfigDirectorySetNoDirectoryTest::prepareEnvironment

Same name in other branches
  1. 8.9.x core/tests/Drupal/FunctionalTests/Installer/InstallerConfigDirectorySetNoDirectoryTest.php \Drupal\FunctionalTests\Installer\InstallerConfigDirectorySetNoDirectoryTest::prepareEnvironment()
  2. 10 core/tests/Drupal/FunctionalTests/Installer/InstallerConfigDirectorySetNoDirectoryTest.php \Drupal\FunctionalTests\Installer\InstallerConfigDirectorySetNoDirectoryTest::prepareEnvironment()
  3. 11.x core/tests/Drupal/FunctionalTests/Installer/InstallerConfigDirectorySetNoDirectoryTest.php \Drupal\FunctionalTests\Installer\InstallerConfigDirectorySetNoDirectoryTest::prepareEnvironment()

Overrides FunctionalTestSetupTrait::prepareEnvironment

File

core/tests/Drupal/FunctionalTests/Installer/InstallerConfigDirectorySetNoDirectoryTest.php, line 29

Class

InstallerConfigDirectorySetNoDirectoryTest
Tests the installer when a custom config directory set up but does not exist.

Namespace

Drupal\FunctionalTests\Installer

Code

protected function prepareEnvironment() {
    parent::prepareEnvironment();
    $this->syncDirectory = $this->publicFilesDirectory . '/config_' . Crypt::randomBytesBase64() . '/sync';
    $this->settings['settings']['config_sync_directory'] = (object) [
        'value' => $this->syncDirectory,
        'required' => TRUE,
    ];
}

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