You are here

protected function GroupCheckTest::getAccessResult in Organic groups 8

Return the access result.

Return value

\Drupal\Core\Access\AccessResultInterface The access result.

4 calls to GroupCheckTest::getAccessResult()
GroupCheckTest::testInvalidEntityType in tests/src/Unit/GroupCheckTest.php
Tests an invalid entity type.
GroupCheckTest::testNoGroup in tests/src/Unit/GroupCheckTest.php
Tests a non-existing group.
GroupCheckTest::testNotGroupType in tests/src/Unit/GroupCheckTest.php
Tests an entity that is not of group type.
GroupCheckTest::testPermissions in tests/src/Unit/GroupCheckTest.php
Tests an in-accessible and accessible routes.

File

tests/src/Unit/GroupCheckTest.php, line 340

Class

GroupCheckTest
Tests the group check access.

Namespace

Drupal\Tests\og\Unit

Code

protected function getAccessResult() {
  $group_check = new GroupCheck($this->entityTypeManager
    ->reveal(), $this->ogAccess
    ->reveal());
  return $group_check
    ->access($this->user
    ->reveal(), $this->route
    ->reveal(), $this->routeMatch
    ->reveal(), $this->entityTypeId, $this->entityId);
}