function UpdateCoreTest::testServiceUnavailable

Tests the Update Manager module when the update server returns 503 errors.

File

drupal/core/modules/update/lib/Drupal/update/Tests/UpdateCoreTest.php, line 186
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 testServiceUnavailable() {
  $this
    ->refreshUpdateStatus(array(), '503-error');

  // Ensure that no "Warning: SimpleXMLElement..." parse errors are found.
  $this
    ->assertNoText('SimpleXMLElement');
  $this
    ->assertUniqueText(t('Failed to get available update data for one project.'));
}