You are here

protected function WebDriverTestBase::installModulesFromClassProperty in Drupal 10

Same name and namespace in other branches
  1. 8 core/tests/Drupal/FunctionalJavascriptTests/WebDriverTestBase.php \Drupal\FunctionalJavascriptTests\WebDriverTestBase::installModulesFromClassProperty()
  2. 9 core/tests/Drupal/FunctionalJavascriptTests/WebDriverTestBase.php \Drupal\FunctionalJavascriptTests\WebDriverTestBase::installModulesFromClassProperty()

Install modules defined by `static::$modules`.

To install test modules outside of the testing environment, add

$settings['extension_discovery_scan_tests'] = TRUE;

to your settings.php.

Parameters

\Symfony\Component\DependencyInjection\ContainerInterface $container: The container.

Overrides FunctionalTestSetupTrait::installModulesFromClassProperty

File

core/tests/Drupal/FunctionalJavascriptTests/WebDriverTestBase.php, line 69

Class

WebDriverTestBase
Runs a browser test using a driver that supports JavaScript.

Namespace

Drupal\FunctionalJavascriptTests

Code

protected function installModulesFromClassProperty(ContainerInterface $container) {
  self::$modules = [
    'js_testing_log_test',
    'jquery_keyevent_polyfill_test',
  ];
  if ($this->disableCssAnimations) {
    self::$modules[] = 'css_disable_transitions_test';
  }
  parent::installModulesFromClassProperty($container);
}