You are here

function SecureSiteTest::testBypassCron in Secure Site 6

Same name and namespace in other branches
  1. 5 tests/securesite.test \SecureSiteTest::testBypassCron()

Test the cron bypass

File

tests/securesite.test, line 426
Secure Site module unit tests

Class

SecureSiteTest
Unit tests for the Secure Site module

Code

function testBypassCron() {
  $this
    ->drupalVariableSet('securesite_enabled', SECURESITE_AUTH);
  $this
    ->drupalVariableSet('securesite_filter_pages_type', SECURESITE_WHITELIST);
  $this
    ->drupalVariableSet('securesite_filter_pages', '');
  $this
    ->drupalGet(url('cron.php', array(
    'absolute' => TRUE,
  )));
  $this
    ->assertResponse('200', t('Bypass: cron') . ': %s');
  $this
    ->assertNoAuthentication();
}