InstallProfileSystemInstall8300Test.php in Drupal 8
File
core/modules/system/tests/src/Functional/Update/InstallProfileSystemInstall8300Test.php
View source
<?php
namespace Drupal\Tests\system\Functional\Update;
use Drupal\Core\Site\Settings;
use Drupal\FunctionalTests\Update\UpdatePathTestBase;
class InstallProfileSystemInstall8300Test extends UpdatePathTestBase {
protected $defaultTheme = 'stark';
protected function setDatabaseDumpFiles() {
$this->databaseDumpFiles = [
__DIR__ . '/../../../../tests/fixtures/update/drupal-8.bare.standard.php.gz',
];
}
public function testUpdate() {
$this
->assertEqual('standard', \Drupal::installProfile());
$this
->assertEqual('standard', Settings::get('install_profile'), 'The install profile has not been written to settings.php.');
$this
->assertNull($this
->config('core.extension')
->get('profile'), 'The install profile is not present in core.extension configuration.');
$this
->runUpdates();
$this
->assertEqual('standard', \Drupal::installProfile());
$this
->assertEqual('standard', Settings::get('install_profile'), 'The install profile has not been written to settings.php.');
$this
->assertEqual('standard', $this
->config('core.extension')
->get('profile'), 'The install profile has been written to core.extension configuration.');
}
}