You are here

public function FieldItemNormalizerDenormalizeExceptionsUnitTest::testFieldItemNormalizerDenormalizeExceptions in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/hal/tests/src/Unit/FieldItemNormalizerDenormalizeExceptionsUnitTest.php \Drupal\Tests\hal\Unit\FieldItemNormalizerDenormalizeExceptionsUnitTest::testFieldItemNormalizerDenormalizeExceptions()

Tests that the FieldItemNormalizer::denormalize() throws proper exceptions.

@dataProvider providerNormalizerDenormalizeExceptions @expectedException \Symfony\Component\Serializer\Exception\InvalidArgumentException

Parameters

array $context: Context for FieldItemNormalizer::denormalize().

File

core/modules/hal/tests/src/Unit/FieldItemNormalizerDenormalizeExceptionsUnitTest.php, line 27
Contains \Drupal\Tests\hal\Unit\FieldItemNormalizerDenormalizeExceptionsUnitTest.

Class

FieldItemNormalizerDenormalizeExceptionsUnitTest
@coversDefaultClass \Drupal\hal\Normalizer\FieldItemNormalizer @group hal

Namespace

Drupal\Tests\hal\Unit

Code

public function testFieldItemNormalizerDenormalizeExceptions($context) {
  $field_item_normalizer = new FieldItemNormalizer();
  $data = array();
  $class = array();
  $field_item_normalizer
    ->denormalize($data, $class, NULL, $context);
}