You are here

function NotificationsAnonymousTests::setUp in Notifications 7

Same name and namespace in other branches
  1. 6.4 tests/notifications_anonymous.test \NotificationsAnonymousTests::setUp()

Set up some required modules

Overrides NotificationsTestCase::setUp

File

tests/notifications_anonymous.test, line 17

Class

NotificationsAnonymousTests

Code

function setUp() {
  parent::setUp('messaging_mail', 'notifications_content', 'notifications_ui', 'notifications_anonymous');
  $this
    ->anonymousCreatePermissions(array(
    'access content',
    'access comments',
    'maintain own subscriptions',
    'subscribe to author',
    'subscribe to content',
    'subscribe to content type',
  ));

  // Set some defaults
  variable_set('notifications_default_send_interval', 0);

  // Immediately
  variable_set('notifications_default_send_method', 'mail');

  // Mail for everybody
  variable_set('messaging_method_mail', array(
    'queue' => 1,
    'log' => 1,
  ));

  // Enable queue, log for mail
  // This send interval (0) and method (mail) are defaults enabled for anonymous
}