You are here

function router_installer_test_modules_installed in Drupal 9

Implements hook_modules_installed().

1 string reference to 'router_installer_test_modules_installed'
InstallerRouterTest::testInstalled in core/tests/Drupal/FunctionalTests/Installer/InstallerRouterTest.php
Confirms that the installation succeeded.

File

core/modules/system/tests/modules/router_installer_test/router_installer_test.module, line 13
Install, update and uninstall functions for the router_installer_test module.

Code

function router_installer_test_modules_installed($modules) {
  if (in_array('router_installer_test', $modules, TRUE)) {

    // Ensure a URL can be generated for routes provided by the module during
    // installation.
    \Drupal::state()
      ->set(__FUNCTION__, Url::fromRoute('router_installer_test.1')
      ->toString());
  }
}