// installed until after extraction.
$validArchiveFile = __DIR__ . '/../../aaa_update_test.tar.gz';
$edit =
[ 'files[project_upload]' =>
$validArchiveFile,
];
$this->
drupalGet('admin/modules/install'
);
$this->
submitForm($edit, 'Continue'
);
$this->
assertSession()->
pageTextContains('AAA Update test is already present.'
);
$this->
assertSession()->
addressEquals('admin/modules/install'
);
// Ensure that a new module can be extracted and installed.
$updaters =
drupal_get_updaters();
$moduleUpdater =
$updaters['module'
]['class'
];
$installedInfoFilePath =
$this->container->
get('update.root'
) . '/' .
$moduleUpdater::
getRootDirectoryRelativePath() . '/update_test_new_module/update_test_new_module.info.yml';
$this->
assertFileDoesNotExist($installedInfoFilePath);
$validArchiveFile = __DIR__ . '/../../update_test_new_module/8.x-1.0/update_test_new_module.tar.gz';
$edit =
[ 'files[project_upload]' =>
$validArchiveFile,
];
$this->
drupalGet('admin/modules/install'
);
$this->
submitForm($edit, 'Continue'
);
// Check that submitting the form takes the user to authorize.php.
$this->
assertSession()->
addressEquals('core/authorize.php'
);