public function EntityConditionGroupNormalizerTest::testDenormalizeException in JSON:API 8
@covers ::denormalize
File
- tests/
src/ Kernel/ Normalizer/ EntityConditionGroupNormalizerTest.php, line 47
Class
- EntityConditionGroupNormalizerTest
- @coversDefaultClass \Drupal\jsonapi\Normalizer\EntityConditionGroupNormalizer @group jsonapi @group jsonapi_normalizers @group legacy
Namespace
Drupal\Tests\jsonapi\Kernel\NormalizerCode
public function testDenormalizeException() {
$normalizer = $this->container
->get('serializer.normalizer.entity_condition_group.jsonapi');
$data = [
'conjunction' => 'NOT_ALLOWED',
'members' => [],
];
$this
->setExpectedException(\InvalidArgumentException::class);
$normalized = $normalizer
->denormalize($data, EntityConditionGroup::class);
}