Skip to content

Merge JaCoCoReport

gaelcolas edited this page Jul 18, 2024 · 1 revision

Merge-JaCoCoReport

SYNOPSIS

Merge two JaCoCoReports into one.

SYNTAX

Merge-JaCoCoReport [-OriginalDocument] <XmlDocument> [-MergeDocument] <XmlDocument>
 [<CommonParameters>]

DESCRIPTION

When you run tests independently for the same module, you may want to get a unified report of all the code paths that were tested. For instance, you want to get a unified report when the runs where done on Linux and Windows.

This function helps merge the results of two runs into one file. If you have more than two reports, keep merging them.

EXAMPLES

EXAMPLE 1

Merge-JaCoCoReport -OriginalDocument 'C:\src\MyModule\Output\JaCoCoRun_linux.xml' -MergeDocument 'C:\src\MyModule\Output\JaCoCoRun_windows.xml'

PARAMETERS

-MergeDocument

Second JaCoCoReports you would like to merge with the other one.

Type: XmlDocument
Parameter Sets: (All)
Aliases:

Required: True
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-OriginalDocument

One of the JaCoCoReports you would like to merge.

Type: XmlDocument
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

System.Xml.XmlDocument

NOTES

See also Update-JaCoCoStatistic that will update the counter elements. Thanks to Yorick (@ykuijs) for this great feature!

RELATED LINKS

Clone this wiki locally