You are here

public function PendingOgMembershipActionTest::accessProvider in Organic groups 8

Data provider for testAccess().

Overrides ActionTestBase::accessProvider

File

tests/src/Kernel/Action/PendingOgMembershipActionTest.php, line 55

Class

PendingOgMembershipActionTest
Tests the PendingOgMembership action plugin.

Namespace

Drupal\Tests\og\Kernel\Action

Code

public function accessProvider() {
  return [
    // Access should be provided if the membership is not already pending and
    // the user executing the action is a privileged user.
    [
      'uid1',
      'member',
    ],
    [
      'uid1',
      'blocked',
    ],
    [
      'uid1',
      'group_administrator',
    ],
    [
      'uid1',
      'group_moderator',
    ],
    [
      'administrator',
      'member',
    ],
    [
      'administrator',
      'blocked',
    ],
    [
      'administrator',
      'group_administrator',
    ],
    [
      'administrator',
      'group_moderator',
    ],
    [
      'group_administrator',
      'member',
    ],
    [
      'group_administrator',
      'blocked',
    ],
    [
      'group_administrator',
      'group_administrator',
    ],
    [
      'group_administrator',
      'group_moderator',
    ],
    [
      'group_moderator',
      'member',
    ],
    [
      'group_moderator',
      'blocked',
    ],
    [
      'group_moderator',
      'group_administrator',
    ],
    [
      'group_moderator',
      'group_moderator',
    ],
    [
      'group_owner',
      'member',
      TRUE,
    ],
    [
      'group_owner',
      'blocked',
      TRUE,
    ],
    [
      'group_owner',
      'group_administrator',
      TRUE,
    ],
    [
      'group_owner',
      'group_moderator',
      TRUE,
    ],
  ];
}