function JsonSchemaTestTrait::getNormalizer

Helper method to retrieve the normalizer.

Override this method if the normalizer has a custom getter or is not already present at $this->normalizer.

Return value

\Symfony\Component\Serializer\Normalizer\NormalizerInterface The normalizer under test.

1 method overrides JsonSchemaTestTrait::getNormalizer()
JsonApiTopLevelResourceNormalizerTest::getNormalizer in core/modules/jsonapi/tests/src/Kernel/Normalizer/JsonApiTopLevelResourceNormalizerTest.php
Helper to load the normalizer.

File

core/modules/serialization/tests/src/Traits/JsonSchemaTestTrait.php, line 141

Class

JsonSchemaTestTrait
Trait for testing JSON Schema validity and fit to sample data.

Namespace

Drupal\Tests\serialization\Traits

Code

protected function getNormalizer() : NormalizerInterface {
    return $this->normalizer;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.