Skip to content

support merging junit reports where the same testsuite exists in multiple files #226

@superflyxxi

Description

@superflyxxi

CircleCI supports running unit tests in parallel. CircleCI can split the work evenly based on testcase or classname time taken. By having it split by classnames, each junit.xml file will have unique classes.

However, ideally we'd want to split by testcase. Some test cases are longer than others. And CircleCI may choose to split a testsuite into two threads. Because of this, one thread will have junit.xml that contains half of the testcases, while another thread will generate a separate junit.xml with the remaining.

When the two get merged, there are two testsuite elements with the same name, but contain diffrerent testcases. Code analysis tools like SonarCloud do not treat this as a valid junit.xml.

Ideally, we should match testsuites by name and not blindly add them in. I can share some examples if need be.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions