class ProfileAutoUninstallTest
Same name and namespace in other branches
- 11.x core/tests/Drupal/FunctionalTests/Installer/ProfileAutoUninstallTest.php \Drupal\FunctionalTests\Installer\ProfileAutoUninstallTest
Tests automatically uninstalling a profile that opts into it.
Attributes
#[Group('Installer')]
#[RunTestsInSeparateProcesses]
Hierarchy
- class \Drupal\Tests\BrowserTestBase uses \Drupal\Tests\DrupalTestCaseTrait, \Drupal\Core\Test\FunctionalTestSetupTrait, \Drupal\Tests\UiHelperTrait, \Drupal\Core\Test\TestSetupTrait, \Drupal\Tests\block\Traits\BlockCreationTrait, \Drupal\Tests\RandomGeneratorTrait, \Drupal\Tests\node\Traits\NodeCreationTrait, \Drupal\Tests\node\Traits\ContentTypeCreationTrait, \Drupal\Tests\ConfigTestTrait, \Drupal\Tests\user\Traits\UserCreationTrait, \Drupal\Tests\XdebugRequestTrait, \Drupal\Tests\ExtensionListTestTrait extends \PHPUnit\Framework\TestCase
- class \Drupal\FunctionalTests\Installer\InstallerTestBase uses \Drupal\Tests\RequirementsPageTrait extends \Drupal\Tests\BrowserTestBase
- class \Drupal\FunctionalTests\Installer\ProfileAutoUninstallTest extends \Drupal\FunctionalTests\Installer\InstallerTestBase
- class \Drupal\FunctionalTests\Installer\InstallerTestBase uses \Drupal\Tests\RequirementsPageTrait extends \Drupal\Tests\BrowserTestBase
Expanded class hierarchy of ProfileAutoUninstallTest
File
-
core/
tests/ Drupal/ FunctionalTests/ Installer/ ProfileAutoUninstallTest.php, line 13
Namespace
Drupal\FunctionalTests\InstallerView source
class ProfileAutoUninstallTest extends InstallerTestBase {
/**
* {@inheritdoc}
*/
protected $profile = 'testing_auto_uninstall';
/**
* {@inheritdoc}
*/
protected $defaultTheme = 'stark';
/**
* Tests that the profile was automatically uninstalled.
*/
public function testAutomaticUninstall() : void {
// The profile included no in-use dependencies, and therefore should
// have been successfully uninstalled.
$extensions = $this->config('core.extension')
->get();
$this->assertArrayNotHasKey($this->profile, $extensions['module']);
$this->assertArrayNotHasKey('profile', $extensions);
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.