You are here

protected function MenuRouterTest::doTestThemeCallbackFakeTheme in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/system/tests/src/Functional/Menu/MenuRouterTest.php \Drupal\Tests\system\Functional\Menu\MenuRouterTest::doTestThemeCallbackFakeTheme()

Tests the theme negotiation when it is set to use a theme that does not exist.

1 call to MenuRouterTest::doTestThemeCallbackFakeTheme()
MenuRouterTest::testThemeIntegration in core/modules/system/tests/src/Functional/Menu/MenuRouterTest.php
Tests theme integration.

File

core/modules/system/tests/src/Functional/Menu/MenuRouterTest.php, line 325

Class

MenuRouterTest
Tests menu router and default menu link functionality.

Namespace

Drupal\Tests\system\Functional\Menu

Code

protected function doTestThemeCallbackFakeTheme() {
  $this
    ->drupalGet('menu-test/theme-callback/use-fake-theme');
  $this
    ->assertSession()
    ->pageTextContains('Active theme: bartik. Actual theme: bartik.');

  // Check that the default theme's CSS appears on the page.
  $this
    ->assertSession()
    ->responseContains('bartik/css/base/elements.css');
}