uninstallModules example

foreach ($required_by_messages as $selector => $message) {
      $assert_session->elementTextContains('css', $selector$message);
    }

    // Uninstall the theme that depends on the modules, and confirm the modules     // can now be uninstalled.     $this->uninstallTheme($theme_name);
    $this->drupalGet('admin/modules/uninstall');

    // Only attempt to uninstall modules not required by the base theme.     $modules_to_uninstall = array_diff($all_dependent_modules$base_theme_module_names);
    $this->uninstallModules($modules_to_uninstall);

    if (!empty($base_theme_to_uninstall)) {
      $this->uninstallTheme($base_theme_to_uninstall);
      $this->drupalGet('admin/modules/uninstall');
      $this->uninstallModules($base_theme_module_names);
    }
  }

  /** * Uninstalls modules via the admin UI. * * @param string[] $module_names * An array of module machine names. */
Home | Imprint | This part of the site doesn't use cookies.