public function OgMembershipTest::testGetOwnerIdOnNewMembership in Organic groups 8
Tests getting the owner ID of a newly created membership.
@covers ::getOwnerId
File
- tests/src/ Kernel/ Entity/ OgMembershipTest.php, line 158 
Class
- OgMembershipTest
- Tests the OgMembership entity.
Namespace
Drupal\Tests\og\Kernel\EntityCode
public function testGetOwnerIdOnNewMembership() {
  // A brand new entity does not have an owner set yet. It should throw a
  // logic exception.
  $membership = OgMembership::create();
  $this
    ->expectException(\LogicException::class);
  $membership
    ->getOwnerId();
}