diff --git a/src/PhpunitMerger/Command/LogCommand.php b/src/PhpunitMerger/Command/LogCommand.php index d30e6ef..5024607 100644 --- a/src/PhpunitMerger/Command/LogCommand.php +++ b/src/PhpunitMerger/Command/LogCommand.php @@ -82,7 +82,8 @@ private function addTestSuites(\DOMElement $parent, array $testSuites) foreach ($testSuites as $testSuite) { if (empty($testSuite['@attributes']['name'])) { if (!empty($testSuite['testsuite'])) { - $this->addTestSuites($parent, $testSuite['testsuite']); + $children = isset($testSuite['testsuite']['@attributes']) ? [$testSuite['testsuite']] : $testSuite['testsuite']; + $this->addTestSuites($parent, $children); } continue; }