installParametersTrait example

if (is_subclass_of($class, TestPreinstallInterface::class)) {
      /** @var \Drupal\TestSite\TestPreinstallInterface $instance */
      $instance = new $class();
      $instance->preinstall($this->databasePrefix, $this->siteDirectory);
    }
  }

  /** * {@inheritdoc} */
  protected function installParameters() {
    $parameters = $this->installParametersTrait();
    $parameters['parameters']['langcode'] = $this->langcode;
    return $parameters;
  }

  /** * {@inheritdoc} */
  protected function changeDatabasePrefix() {
    // Ensure that we use the database from SIMPLETEST_DB environment variable.     Database::removeConnection('default');
    $this->changeDatabasePrefixTrait();
  }
Home | Imprint | This part of the site doesn't use cookies.