1 theme.test ThemeUnitTest::testThemeGetSetting()

Test the theme_get_setting() function.

File

core/modules/simpletest/tests/theme.test, line 139
Tests for the theme API.

Class

ThemeUnitTest
Unit tests for the Theme API.

Code

function testThemeGetSetting() {
  $GLOBALS['theme_key'] = 'test_theme';
  $this->assertIdentical(theme_get_setting('theme_test_setting'), 'default value', 'theme_get_setting() uses the default theme automatically.');
  $this->assertNotEqual(theme_get_setting('subtheme_override', 'test_basetheme'), theme_get_setting('subtheme_override', 'test_subtheme'), 'Base theme\'s default settings values can be overridden by subtheme.');
  $this->assertIdentical(theme_get_setting('basetheme_only', 'test_subtheme'), 'base theme value', 'Base theme\'s default settings values are inherited by subtheme.');
}