You are here

public function TypedDataNormalizerTest::testNormalize in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/serialization/tests/src/Unit/Normalizer/TypedDataNormalizerTest.php \Drupal\Tests\serialization\Unit\Normalizer\TypedDataNormalizerTest::testNormalize()

Tests the normalize() method.

File

core/modules/serialization/tests/src/Unit/Normalizer/TypedDataNormalizerTest.php, line 50
Contains \Drupal\Tests\serialization\Unit\Normalizer\TypedDataNormalizerTest.

Class

TypedDataNormalizerTest
@coversDefaultClass \Drupal\serialization\Normalizer\TypedDataNormalizer @group serialization

Namespace

Drupal\Tests\serialization\Unit\Normalizer

Code

public function testNormalize() {
  $this->typedData
    ->expects($this
    ->once())
    ->method('getValue')
    ->will($this
    ->returnValue('test'));
  $this
    ->assertEquals('test', $this->normalizer
    ->normalize($this->typedData));
}