You are here

function NotificationsTestCase::enableUIPages in Notifications 7

Same name and namespace in other branches
  1. 6.4 tests/notifications_test_case.inc \NotificationsTestCase::enableUIPages()
3 calls to NotificationsTestCase::enableUIPages()
NotificationsAnonymousTests::testAnonymousSubscriptions in tests/notifications_anonymous.test
NotificationsContentTests::testNotificationsContent in tests/notifications_content.test
Play with creating, retrieving, deleting a pair subscriptions
NotificationsContentTests::testNotificationsUserPages in tests/notifications_content.test
Check all user pages before and after enabling permissions

File

tests/notifications_test_case.inc, line 45
Base class for Notifications Tests

Class

NotificationsTestCase
@file Base class for Notifications Tests

Code

function enableUIPages($enable = TRUE) {
  $settings = array_keys(notifications_subscription_types());
  variable_set('notifications_ui_types', $enable ? $settings : array());
  variable_set('notifications_ui_user_options', $enable ? array(
    'page',
    'create',
  ) : array());
  menu_rebuild();
}