You are here

public function GroupTypeTest::testHasContentPlugin in Group 2.0.x

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

Tests whether a group type can tell if it has a plugin installed.

@covers ::hasContentPlugin

File

tests/src/Kernel/GroupTypeTest.php, line 68

Class

GroupTypeTest
Tests the general behavior of group type entities.

Namespace

Drupal\Tests\group\Kernel

Code

public function testHasContentPlugin() {
  $this
    ->assertTrue($this->groupType
    ->hasContentPlugin('group_membership'), 'Found the group_membership plugin.');
  $this
    ->assertFalse($this->groupType
    ->hasContentPlugin('fake_plugin_id'), 'Could not find the fake_plugin_id plugin.');
}