'inner' =>
['foo' => 'foo', 'bar' => 'bar'
],
], DummyWithConstructorObjectAndDefaultValue::
class, null,
$context));
} public function testNormalizeSameObjectWithDifferentAttributes() { $classMetadataFactory =
new ClassMetadataFactory(new AnnotationLoader());
$this->normalizer =
new ObjectNormalizer($classMetadataFactory);
$serializer =
new Serializer([$this->normalizer
]);
$this->normalizer->
setSerializer($serializer);
$dummy =
new ObjectOuter();
$dummy->foo =
new ObjectInner();
$dummy->foo->foo = 'foo.foo';
$dummy->foo->bar = 'foo.bar';
$dummy->bar =
new ObjectInner();
$dummy->bar->foo = 'bar.foo';
$dummy->bar->bar = 'bar.bar';
$this->
assertEquals([ 'foo' =>
[ 'bar' => 'foo.bar',
],