You are here

public function AgreementMultipleRoleTestCase::testNoAgreementWithoutRole in Agreement 7.2

Asserts that user does not get agreement page without roles.

File

./agreement.test, line 719
Tests for Agreement module.

Class

AgreementMultipleRoleTestCase
Tests multiple roles applying to an agreement.

Code

public function testNoAgreementWithoutRole() {

  // Creates user, login and assert no agreement page.
  $this
    ->unprivilegedUserLogin();
  $this
    ->isNotAgreementPage($this->agreement);

  // Go to front page, no agreement.
  $this
    ->drupalGet('node');
  $this
    ->isNotAgreementPage($this->agreement);

  // Go anywhere else, no agreement.
  $this
    ->drupalGet('user/' . $this->unprivilegedUser->uid);
  $this
    ->isNotAgreementPage($this->agreement);
}