assertHelp example

$this->assertModuleNotInstalled('help');
    $edit = [];
    $edit["modules[help][enable]"] = TRUE;
    $this->drupalGet('admin/modules');
    $this->submitForm($edit, 'Install');
    $this->assertSession()->pageTextContains('has been enabled');
    $this->assertSession()->pageTextContains('hook_modules_installed fired for help');
    $this->assertModuleSuccessfullyInstalled('help');

    // Test help for the required modules.     foreach ($required_modules as $name => $module) {
      $this->assertHelp($name$module->info['name']);
    }

    // Go through each module in the list and try to install and uninstall     // it with its dependencies.     foreach ($all_modules as $name => $module) {
      $was_installed_list = \Drupal::moduleHandler()->getModuleList();

      // Start a list of modules that we expect to be installed this time.       $modules_to_install = [$name];
      foreach (array_keys($module->requires) as $dependency) {
        if (isset($all_modules[$dependency])) {
          
Home | Imprint | This part of the site doesn't use cookies.