You are here

protected function FieldHelper::getFieldStorageMock in Feeds Paragraphs 8

File

tests/src/Unit/Helpers/FieldHelper.php, line 141

Class

FieldHelper

Namespace

Drupal\Tests\feeds_para_mapper\Unit\Helpers

Code

protected function getFieldStorageMock(FieldConfig $config) {
  $storage = $this->prophet
    ->prophesize(FieldStorageDefinitionInterface::class);
  $storage
    ->getCardinality()
    ->willReturn((string) $config->cardinality);
  return $storage
    ->reveal();
}