You are here

protected function BillingPeriodItemTest::setUp in Commerce Recurring Framework 8

Overrides KernelTestBase::setUp

File

tests/src/Kernel/BillingPeriodItemTest.php, line 36

Class

BillingPeriodItemTest
Tests the billing period field type.

Namespace

Drupal\Tests\commerce_recurring\Kernel

Code

protected function setUp() : void {
  parent::setUp();
  $this
    ->installEntitySchema('user');
  $this
    ->installEntitySchema('entity_test');
  FieldStorageConfig::create([
    'entity_type' => 'entity_test',
    'field_name' => 'field_billing_period',
    'type' => 'commerce_billing_period',
  ])
    ->save();
  FieldConfig::create([
    'entity_type' => 'entity_test',
    'field_name' => 'field_billing_period',
    'bundle' => 'entity_test',
  ])
    ->save();
}