You are here

public function SecureSiteTypeFormGuestFunctionalTest::testSecureSiteTypeFormGuestUnsetRandomNoAccess in Secure Site 7.2

Same name and namespace in other branches
  1. 6.2 securesite.test \SecureSiteTypeFormGuestFunctionalTest::testSecureSiteTypeFormGuestUnsetRandomNoAccess()

Request home page with random credentials and access disabled.

File

./securesite.test, line 1625
Tests for Secure Site module.

Class

SecureSiteTypeFormGuestFunctionalTest
Functional tests for form authentication with guest credentials.

Code

public function testSecureSiteTypeFormGuestUnsetRandomNoAccess() {
  $this
    ->drupalPost('', array(
    'name' => $this
      ->randomName(),
    'pass' => user_password(),
  ), 'Log in');
  $this
    ->assertFieldByXPath('//form[@id="securesite-user-login"]', '', t('Requesting home page with random credentials and guest access disabled.'));
  $this
    ->assertText('Unrecognized user name and/or password.', t('Checking for error message when guest access is disabled and random password is given.'));
}