// The module should not be enabled and there should be a warning and a
// list of the deprecated modules with only this one.
$assert->pageTextNotContains('2 modules have been installed: Deprecated module with non deprecated dependency, Drupal system listing compatible test');
$assert->pageTextContains('Deprecated modules are modules that may be removed from the next major release of Drupal core. Use at your own risk.');
$assert->pageTextContains('The Deprecated module with non deprecated dependency module is deprecated');
// There should be a warning about enabling deprecated modules, but no
// warnings about experimental modules.
$this->assertSession()->pageTextContains('Are you sure you wish to install a deprecated module?');
$this->assertSession()->pageTextNotContains('Are you sure you wish to install an experimental module?');
$this->assertSession()->pageTextNotContains('Are you sure you wish to install experimental and deprecated modules?');
// Ensure the non-deprecated dependency module is not listed as deprecated.
$assert->pageTextNotContains('The Drupal system listing compatible test module is deprecated');
// There should be a message about enabling dependencies.
$assert->pageTextContains('You must install the following module to install Deprecated module with non deprecated dependency:Drupal system listing compatible test');
// Enable the module and confirm that it worked.
$this->submitForm([],'Continue');
$assert->pageTextContains('2 modules have been installed: Deprecated module with non deprecated dependency, Drupal system listing compatible test.');
$assert->pageTextContains('Deprecated modules are modules that may be removed from the next major release of Drupal core and the relevant contributed module. Use at your own risk.');
// The module should not be enabled and there should be a warning and a
// list of the deprecated modules with only this one.
$assert->pageTextNotContains('2 modules have been installed: Deprecated module with non deprecated dependency, Drupal system listing compatible test');
$assert->pageTextContains('Deprecated modules are modules that may be removed from the next major release of Drupal core. Use at your own risk.');
$assert->pageTextContains('The Deprecated module with non deprecated dependency module is deprecated');
// There should be a warning about enabling deprecated modules, but no
// warnings about experimental modules.
$this->assertSession()->pageTextContains('Are you sure you wish to install a deprecated module?');
$this->assertSession()->pageTextNotContains('Are you sure you wish to install an experimental module?');
$this->assertSession()->pageTextNotContains('Are you sure you wish to install experimental and deprecated modules?');
// Ensure the non-deprecated dependency module is not listed as deprecated.
$assert->pageTextNotContains('The Drupal system listing compatible test module is deprecated');
// There should be a message about enabling dependencies.
$assert->pageTextContains('You must install the following module to install Deprecated module with non deprecated dependency:Drupal system listing compatible test');
// Enable the module and confirm that it worked.
$this->submitForm([],'Continue');
$assert->pageTextContains('2 modules have been installed: Deprecated module with non deprecated dependency, Drupal system listing compatible test.');
$assert->pageTextContains('Deprecated modules are modules that may be removed from the next major release of Drupal core and the relevant contributed module. Use at your own risk.');
}
/**
* Tests installing deprecated and experimental modules at the same time.