function metatag_test_menu in Metatag 7
Implements hook_menu().
Provides simple pages to test against.
1 call to metatag_test_menu()
- MetatagCoreWithI18nOutputTest::testMenuPaths in tests/
MetatagCoreWithI18nOutputTest.test - Test the menu paths.
File
- tests/
metatag_test.module, line 22 - Primary hook implementations for the Metatag Test module.
Code
function metatag_test_menu() {
$string = 'moosqueakoinkmeow';
$defaults = array(
'page callback' => 'metatag_test_page_callback',
'access callback' => TRUE,
'type' => MENU_NORMAL_ITEM,
);
$items[$string] = array(
'title' => 'Test page',
'description' => 'An average page.',
) + $defaults;
// 255 / 19 chars = 13.
$long_path = implode('/', array_pad(array(), 13, $string));
$items[$long_path . '/%'] = array(
'title' => 'Test page with really long URL',
'description' => 'The URL is really, really, really long.',
'page arguments' => array(
13,
),
) + $defaults;
// User-specific meta tags.
$items['account-test-page'] = array(
'title' => 'User test page',
'description' => 'Test how user tokens are handled.',
'page callback' => 'metatag_test_user_page_callback',
) + $defaults;
return $items;
}