You are here

public function RevisionFieldTest::createTestEntity in Multiversion 8.2

1 call to RevisionFieldTest::createTestEntity()
RevisionFieldTest::testFieldOperations in src/Tests/RevisionFieldTest.php

File

src/Tests/RevisionFieldTest.php, line 83

Class

RevisionFieldTest
Test the creation and operation of the Revision field.

Namespace

Drupal\multiversion\Tests

Code

public function createTestEntity(EntityStorageInterface $storage, array $values) {
  switch ($storage
    ->getEntityTypeId()) {
    case 'block_content':
      $values['info'] = $this
        ->randomMachineName();
      break;
  }
  return $storage
    ->create($values);
}