You are here

public function GroupToGroupContentRelationshipTest::testGroupOwnerIsListed in Group 2.0.x

Same name and namespace in other branches
  1. 8 tests/src/Kernel/Views/GroupToGroupContentRelationshipTest.php \Drupal\Tests\group\Kernel\Views\GroupToGroupContentRelationshipTest::testGroupOwnerIsListed()

Tests that a group's owner (default member) is returned by the view.

File

tests/src/Kernel/Views/GroupToGroupContentRelationshipTest.php, line 147

Class

GroupToGroupContentRelationshipTest
Tests the group_to_group_content relationship handler.

Namespace

Drupal\Tests\group\Kernel\Views

Code

public function testGroupOwnerIsListed() {
  $this
    ->assertEquals(0, count($this
    ->getViewResults()), 'The view displays no members.');
  $this
    ->createGroup();
  $this
    ->assertEquals(1, count($this
    ->getViewResults()), 'The view displays the default member.');
}