summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwebchick2011-06-27 07:27:41 (GMT)
committer webchick2011-06-27 07:27:41 (GMT)
commite85b057acb349cfdcacc508a43d4784410027a32 (patch)
tree4b191b6c15db1f6b1aeef521d7a81cd2e4995713
parenta1ac3f6d95bd765ac054f816902c8214a0420caf (diff)
Issue #992376 follow-up by larowlan: Tests for paths containing a hyphen and theme_hook_suggestions().
-rw-r--r--modules/simpletest/tests/theme.test5
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/simpletest/tests/theme.test b/modules/simpletest/tests/theme.test
index d0ad77d..f1e1bd5 100644
--- a/modules/simpletest/tests/theme.test
+++ b/modules/simpletest/tests/theme.test
@@ -42,6 +42,11 @@ class ThemeUnitTest extends DrupalWebTestCase {
$args = array('node', "1\0");
$suggestions = theme_get_suggestions($args, 'page');
$this->assertEqual($suggestions, array('page__node', 'page__node__%', 'page__node__1'), t('Removed invalid \\0 from suggestions'));
+ // Define path with hyphens to be used to generate suggestions.
+ $args = array('node', '1', 'hyphen-path');
+ $result = array('page__node', 'page__node__%', 'page__node__1', 'page__node__hyphen_path');
+ $suggestions = theme_get_suggestions($args, 'page');
+ $this->assertEqual($suggestions, $result, t('Found expected page suggestions for paths containing hyphens.'));
}
/**