diff --git a/core/modules/system/lib/Drupal/system/Tests/System/StatusTest.php b/core/modules/system/lib/Drupal/system/Tests/System/StatusTest.php new file mode 100644 index 0000000000000000000000000000000000000000..e2a4298f6c306447b42a36f78d2c96842f2b686c --- /dev/null +++ b/core/modules/system/lib/Drupal/system/Tests/System/StatusTest.php @@ -0,0 +1,49 @@ +<?php + +/** + * @file + * Contains \Drupal\system\Tests\System\StatusTest. + */ + +namespace Drupal\system\Tests\System; + +use Drupal\simpletest\WebTestBase; + +/** + * Tests administrative status page. + */ +class StatusTest extends WebTestBase { + + /** + * {@inheritdoc} + */ + public static function getInfo() { + return array( + 'name' => 'Status page', + 'description' => 'Tests output on the status overview page.', + 'group' => 'System', + ); + } + + /** + * {@inheritdoc} + */ + protected function setUp() { + parent::setUp(); + + $admin_user = $this->drupalCreateUser(array( + 'administer site configuration', + )); + $this->drupalLogin($admin_user); + } + + /** + * Tests that the status page returns. + */ + public function testStatusPage() { + // Go to Administration. + $this->drupalGet('admin/reports/status'); + $this->assertResponse(200, 'The status page is reachable.'); + } + +} diff --git a/core/modules/system/system.routing.yml b/core/modules/system/system.routing.yml index 4d56d473504aaf1b8da8484406f3a2ce2bc37bc6..fadc21ab9ba1c6cad0106deef54641997fb87e4a 100644 --- a/core/modules/system/system.routing.yml +++ b/core/modules/system/system.routing.yml @@ -272,7 +272,7 @@ system.theme_enable: system.status: path: '/admin/reports/status' defaults: - _controller: 'Drupal\system\Controller\SystemInfoController::status' + _content: 'Drupal\system\Controller\SystemInfoController::status' _title: 'Status report' requirements: _permission: 'administer site configuration'