You are here

public function ClaroTest::testIsUninstallable in Drupal 9

Same name and namespace in other branches
  1. 8 core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php \Drupal\FunctionalTests\Theme\ClaroTest::testIsUninstallable()
  2. 10 core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php \Drupal\FunctionalTests\Theme\ClaroTest::testIsUninstallable()

Tests that the Claro theme can be uninstalled, despite being experimental.

@todo Remove in https://www.drupal.org/project/drupal/issues/3066007

File

core/tests/Drupal/FunctionalTests/Theme/ClaroTest.php, line 64

Class

ClaroTest
Tests the Claro theme.

Namespace

Drupal\FunctionalTests\Theme

Code

public function testIsUninstallable() {
  $this
    ->drupalLogin($this
    ->drupalCreateUser([
    'access administration pages',
    'administer themes',
  ]));
  $this
    ->drupalGet('admin/appearance');
  $this
    ->cssSelect('a[title="Install Seven as default theme"]')[0]
    ->click();
  $this
    ->cssSelect('a[title="Uninstall Claro theme"]')[0]
    ->click();
  $this
    ->assertSession()
    ->pageTextContains('The Claro theme has been uninstalled.');
}