You are here

protected function InstallerCustomConfigDirectoryCreateTest::prepareEnvironment in Drupal 8

Prepares the current environment for running the test.

Also sets up new resources for the testing environment, such as the public filesystem and configuration directories.

This method is private as it must only be called once by BrowserTestBase::setUp() (multiple invocations for the same test would have unpredictable consequences) and it must not be callable or overridable by test classes.

Overrides FunctionalTestSetupTrait::prepareEnvironment

File

core/tests/Drupal/FunctionalTests/Installer/InstallerCustomConfigDirectoryCreateTest.php, line 23

Class

InstallerCustomConfigDirectoryCreateTest
Tests the installer when a custom config_directory set up but does not exist.

Namespace

Drupal\FunctionalTests\Installer

Code

protected function prepareEnvironment() {
  parent::prepareEnvironment();

  // Other directories will be created too.
  // This is legacy functionality.
  $this->settings['config_directories']['custom'] = (object) [
    'value' => $this->publicFilesDirectory . '/config_custom',
    'required' => TRUE,
  ];
}