feat: support normalizing Ds\Collection
#1079
Annotations
2 warnings
Mutation tests
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions/cache@v3, actions/cache@v3.2.5. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
|
Mutation tests:
src/Normalizer/Transformer/RecursiveTransformer.php#L124
Escaped Mutant for Mutator "UnwrapArrayMap":
--- Original
+++ New
@@ @@
return array_map(fn(mixed $value) => $this->doTransform($value, $references), (array) $value);
}
if ($value instanceof \Ds\Collection) {
- return array_map(fn(mixed $value) => $this->doTransform($value, $references), iterator_to_array($value));
+ return iterator_to_array($value);
}
$values = (fn() => get_object_vars($this))->call($value);
$transformed = [];
|