Include only unique coverage reports in artifact

The test runner is creating *two* cobertura.xml files for each test run. Besides doubling the size of the coverageResults artifact, this makes the `publish-codecoverage.yml` pipeline step do much more work which can take *minutes* instead of seconds.
This commit is contained in:
Andrew Arnott 2022-06-14 13:20:10 -06:00
Родитель f064b9a150
Коммит e903112e9e
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: F33A420C60ED9C6F
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -1,6 +1,6 @@
$RepoRoot = [System.IO.Path]::GetFullPath("$PSScriptRoot\..\..")
$coverageFiles = @(Get-ChildItem "$RepoRoot/test/*.cobertura.xml" -Recurse)
$coverageFiles = @(Get-ChildItem "$RepoRoot/test/*.cobertura.xml" -Recurse | Where {$_.FullName -notlike "*/In/*" -and $_.FullName -notlike "*\In\*" })
# Prepare code coverage reports for merging on another machine
if ($env:SYSTEM_DEFAULTWORKINGDIRECTORY) {