You are here

protected function OpignoPollAppWebTestCase::createTestRoles in Opigno Poll App 7

Helper method to create 3 different OG roles for testing.

1 call to OpignoPollAppWebTestCase::createTestRoles()
OpignoPollAppWebTestCase::setUp in tests/OpignoPollAppWebTestCase.test
Sets up a Drupal site for running functional and integration tests.

File

tests/OpignoPollAppWebTestCase.test, line 255
Defines the unit tests for Opigno Poll.

Class

OpignoPollAppWebTestCase
@file Defines the unit tests for Opigno Poll.

Code

protected function createTestRoles() {
  $this
    ->createRole('can vote', array(
    'vote on polls',
  ));
  $this
    ->createRole('can cancel', array(
    'cancel own vote',
  ));
  $this
    ->createRole('can see all', array(
    'inspect all votes',
  ));
}