InstallerExistingInstallationTest.php in Zircon Profile 8.0
Same filename and directory in other branches
Namespace
Drupal\system\Tests\InstallerFile
core/modules/system/src/Tests/Installer/InstallerExistingInstallationTest.phpView source
<?php
/**
* @file
* Contains \Drupal\system\Tests\Installer\InstallerExistingInstallationTest.
*/
namespace Drupal\system\Tests\Installer;
use Drupal\simpletest\InstallerTestBase;
/**
* Tests the installer with an existing Drupal installation.
*
* @group Installer
*/
class InstallerExistingInstallationTest extends InstallerTestBase {
/**
* {@inheritdoc}
*/
protected function setUp() {
parent::setUp();
}
/**
* Verifies that Drupal can't be reinstalled while an existing installation is
* available.
*/
public function testInstaller() {
// Verify that Drupal can't be immediately reinstalled.
$this
->drupalGet($GLOBALS['base_url'] . '/core/install.php');
$this
->assertRaw('Drupal already installed');
// Delete settings.php and attempt to reinstall again.
unlink($this->siteDirectory . '/settings.php');
$this
->drupalGet($GLOBALS['base_url'] . '/core/install.php');
$this
->setUpLanguage();
$this
->setUpProfile();
$this
->setUpSettings();
$this
->assertRaw('Drupal already installed');
}
}
Classes
Name | Description |
---|---|
InstallerExistingInstallationTest | Tests the installer with an existing Drupal installation. |