You are here

public function GetSetMethodNormalizerTest::testDenormalizeWithObject in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/serializer/Tests/Normalizer/GetSetMethodNormalizerTest.php \Symfony\Component\Serializer\Tests\Normalizer\GetSetMethodNormalizerTest::testDenormalizeWithObject()

File

vendor/symfony/serializer/Tests/Normalizer/GetSetMethodNormalizerTest.php, line 92

Class

GetSetMethodNormalizerTest

Namespace

Symfony\Component\Serializer\Tests\Normalizer

Code

public function testDenormalizeWithObject() {
  $data = new \stdClass();
  $data->foo = 'foo';
  $data->bar = 'bar';
  $data->fooBar = 'foobar';
  $obj = $this->normalizer
    ->denormalize($data, __NAMESPACE__ . '\\GetSetDummy', 'any');
  $this
    ->assertEquals('foo', $obj
    ->getFoo());
  $this
    ->assertEquals('bar', $obj
    ->getBar());
}