You are here

function UpdateCoreTest::testServiceUnavailable in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/update/src/Tests/UpdateCoreTest.php \Drupal\update\Tests\UpdateCoreTest::testServiceUnavailable()

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

File

core/modules/update/src/Tests/UpdateCoreTest.php, line 296
Contains \Drupal\update\Tests\UpdateCoreTest.

Class

UpdateCoreTest
Tests the Update Manager module through a series of functional tests using mock XML data.

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.'));
}