function RouterTest::testThemeCallbackAdministrative

Test the theme callback when it is set to use an administrative theme.

File

drupal/core/modules/system/lib/Drupal/system/Tests/Menu/RouterTest.php, line 95
Definition of Drupal\system\Tests\Menu\RouterTest.

Class

RouterTest
Tests menu router and hook_menu() functionality.

Namespace

Drupal\system\Tests\Menu

Code

function testThemeCallbackAdministrative() {
  theme_enable(array(
    'seven',
  ));
  $this
    ->drupalGet('menu-test/theme-callback/use-admin-theme');
  $this
    ->assertText('Custom theme: seven. Actual theme: seven.', 'The administrative theme can be correctly set in a theme callback.');
  $this
    ->assertRaw('seven/style.css', "The administrative theme's CSS appears on the page.");
}