private function getDenormalizerForDummyCollection() { $extractor =
$this->
createMock(PhpDocExtractor::
class);
$extractor->
method('getTypes'
) ->
will($this->
onConsecutiveCalls( [new Type('array', false, null, true,
new Type('int'
),
new Type('object', false, DummyChild::
class))],
null
));
$denormalizer =
new AbstractObjectNormalizerCollectionDummy(null, null,
$extractor);
$arrayDenormalizer =
new ArrayDenormalizerDummy();
$serializer =
new SerializerCollectionDummy([$arrayDenormalizer,
$denormalizer]);
$arrayDenormalizer->
setSerializer($serializer);
$denormalizer->
setSerializer($serializer);
return $denormalizer;
} public function testDenormalizeStringCollectionDecodedFromXmlWithOneChild() { $denormalizer =
$this->
getDenormalizerForStringCollection();
// if an xml-node can have children which should be deserialized as string[]