You are here

protected function MediaBehaviorSettingsFormTest::createEntityBundle in Rabbit Hole 8

Same name and namespace in other branches
  1. 2.x modules/rh_media/tests/src/Functional/MediaBehaviorSettingsFormTest.php \Drupal\Tests\rh_media\Functional\MediaBehaviorSettingsFormTest::createEntityBundle()

Creates new entity bundle.

Return value

string ID of the created bundle.

Overrides RabbitHoleBehaviorSettingsFormTestBase::createEntityBundle

File

modules/rh_media/tests/src/Functional/MediaBehaviorSettingsFormTest.php, line 44

Class

MediaBehaviorSettingsFormTest
Test the functionality of the rabbit hole form additions to the media.

Namespace

Drupal\Tests\rh_media\Functional

Code

protected function createEntityBundle() {

  // TODO: Remove 2nd parameter once https://www.drupal.org/node/3174874 is
  // resolved.
  $this->bundle = $this
    ->createMediaType('test', [
    'id' => mb_strtolower($this
      ->randomMachineName()),
  ]);
  return $this->bundle
    ->id();
}