function UpdateCoreTest::testModulePageRegularUpdate

Checks the messages at admin/modules when an update is missing.

File

drupal/core/modules/update/lib/Drupal/update/Tests/UpdateCoreTest.php, line 135
Definition of Drupal\update\Tests\UpdateCoreTest.

Class

UpdateCoreTest
Tests behavior related to discovering and listing updates to Drupal core.

Namespace

Drupal\update\Tests

Code

function testModulePageRegularUpdate() {
  $this
    ->setSystemInfo7_0();

  // Instead of using refreshUpdateStatus(), set these manually.
  config('update.settings')
    ->set('fetch.url', url('update-test', array(
    'absolute' => TRUE,
  )))
    ->save();
  config('update_test.settings')
    ->set('xml_map', array(
    'drupal' => '1',
  ))
    ->save();
  $this
    ->drupalGet('admin/reports/updates');
  $this
    ->clickLink(t('Check manually'));
  $this
    ->assertText(t('Checked available update data for one project.'));
  $this
    ->drupalGet('admin/modules');
  $this
    ->assertText(t('There are updates available for your version of Drupal.'));
  $this
    ->assertNoText(t('There is a security update available for your version of Drupal.'));
}