You are here

public function StandaloneTest::testGetters in Commerce Recurring Framework 8

@covers ::getLabel @covers ::getPurchasableEntityTypeId

File

tests/src/Kernel/Plugin/Commerce/SubscriptionType/StandaloneTest.php, line 23

Class

StandaloneTest
Tests the standalone subscription type.

Namespace

Drupal\Tests\commerce_recurring\Kernel\Plugin\Commerce\SubscriptionType

Code

public function testGetters() {
  $plugin_manager = $this->container
    ->get('plugin.manager.commerce_subscription_type');

  /** @var \Drupal\commerce_recurring\Plugin\Commerce\SubscriptionType\SubscriptionTypeInterface $plugin */
  $plugin = $plugin_manager
    ->createInstance('standalone');
  $this
    ->assertEquals('Standalone', $plugin
    ->getLabel());
  $this
    ->assertNull($plugin
    ->getPurchasableEntityTypeId());
}