function UpdateUploadTest::testUpdateManagerCoreSecurityUpdateMessages in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/update/src/Tests/UpdateUploadTest.php \Drupal\update\Tests\UpdateUploadTest::testUpdateManagerCoreSecurityUpdateMessages()
Checks the messages on update manager pages when missing a security update.
File
- core/
modules/ update/ src/ Tests/ UpdateUploadTest.php, line 145 - Contains \Drupal\update\Tests\UpdateUploadTest.
Class
- UpdateUploadTest
- Tests the Update Manager module's upload and extraction functionality.
Namespace
Drupal\update\TestsCode
function testUpdateManagerCoreSecurityUpdateMessages() {
$setting = array(
'#all' => array(
'version' => '8.0.0',
),
);
$this
->config('update_test.settings')
->set('system_info', $setting)
->set('xml_map', array(
'drupal' => '0.2-sec',
))
->save();
$this
->config('update.settings')
->set('fetch.url', Url::fromRoute('update_test.update_test')
->setAbsolute()
->toString())
->save();
// Initialize the update status.
$this
->drupalGet('admin/reports/updates');
// Now, make sure none of the Update manager pages have duplicate messages
// about core missing a security update.
$this
->drupalGet('admin/modules/install');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
$this
->drupalGet('admin/modules/update');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
$this
->drupalGet('admin/appearance/install');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
$this
->drupalGet('admin/appearance/update');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
$this
->drupalGet('admin/reports/updates/install');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
$this
->drupalGet('admin/reports/updates/update');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
$this
->drupalGet('admin/update/ready');
$this
->assertNoText(t('There is a security update available for your version of Drupal.'));
}