You are here

public function PatternsSystemTestCase::testTheme in Patterns 7.2

Same name and namespace in other branches
  1. 7 tests/system/system.test \PatternsSystemTestCase::testTheme()

File

tests/system/system.test, line 92
SimpleTests for the System component of Patterns.

Class

PatternsSystemTestCase
@file SimpleTests for the System component of Patterns.

Code

public function testTheme() {

  // Check for the current theme.
  $this
    ->assertIdentical(variable_get('theme_default', NULL), 'bartik', t('The default theme is bartik.'));
  $this
    ->assertIdentical(variable_get('admin_theme', NULL), 'seven', t('The default admin theme is seven.'));

  // Run the pattern.
  parent::runFile('theme.yaml', 'Set theme', $this->system_tests_dir);

  // Check for the current theme after running the pattern.
  $this
    ->assertIdentical(variable_get('theme_default', NULL), 'garland', t('The default theme is garland.'));
  $this
    ->assertIdentical(variable_get('admin_theme', NULL), 'bartik', t('The default admin theme is bartik.'));
}