Skip to content
Snippets Groups Projects
Verified Commit 68693249 authored by Lee Rowlands's avatar Lee Rowlands
Browse files

Issue #3033494 by alexpott, dww, tim.plunkett: SiteConfigureForm can install...

Issue #3033494 by alexpott, dww, tim.plunkett: SiteConfigureForm can install the file module without the field module

(cherry picked from commit 5d2bc249)
parent 6f3f6fb3
No related branches found
No related tags found
No related merge requests found
......@@ -293,7 +293,7 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
// Enable update.module if this option was selected.
$update_status_module = $form_state->getValue('enable_update_status_module');
if (empty($install_state['config_install_path']) && $update_status_module) {
$this->moduleInstaller->install(['file', 'update'], FALSE);
$this->moduleInstaller->install(['update']);
// Add the site maintenance account's email address to the list of
// addresses to be notified when updates are available, if selected.
......
<?php
namespace Drupal\FunctionalTests\Installer;
use Drupal\Tests\BrowserTestBase;
/**
* Tests installing the Testing profile with update notifications on.
*
* @group Installer
*/
class TestingProfileInstallTest extends BrowserTestBase {
/**
* {@inheritdoc}
*/
protected $profile = 'testing';
/**
* Ensure the Update module and its dependencies are installed.
*/
public function testUpdateModuleInstall() {
$this->assertTrue(
\Drupal::moduleHandler()->moduleExists('update') && \Drupal::moduleHandler()->moduleExists('file') && \Drupal::moduleHandler()->moduleExists('field'),
'The Update module and its dependencies are installed.'
);
}
/**
* {@inheritdoc}
*/
protected function installParameters() {
$params = parent::installParameters();
$params['forms']['install_configure_form']['enable_update_status_module'] = TRUE;
return $params;
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment