This commit is contained in:
Eilon Lipton 2019-10-03 12:58:19 -07:00
Родитель a5d8d03427
Коммит 4e8522cc16
1 изменённых файлов: 0 добавлений и 22 удалений

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

@ -1,22 +0,0 @@
$RepoRoot = [System.IO.Path]::GetFullPath("$PSScriptRoot\..\..")
# Prepare code coverage reports for merging on another machine
if ($env:SYSTEM_DEFAULTWORKINGDIRECTORY) {
Write-Host "Substituting $env:SYSTEM_DEFAULTWORKINGDIRECTORY with `"{reporoot}`""
$reports = Get-ChildItem "$RepoRoot/bin/coverage.cobertura.xml" -Recurse
$reports |% {
$content = Get-Content -Path $_ |% { $_ -Replace [regex]::Escape($env:SYSTEM_DEFAULTWORKINGDIRECTORY), "{reporoot}" }
Set-Content -Path $_ -Value $content -Encoding UTF8
}
} else {
Write-Warning "coverageResults: Azure Pipelines not detected. Machine-neutral token replacement skipped."
}
if (!((Test-Path $RepoRoot\bin) -and (Test-Path $RepoRoot\obj))) { return }
@{
$RepoRoot = (
@(Get-ChildItem "$RepoRoot\bin\coverage.cobertura.xml" -Recurse) +
(Get-ChildItem "$RepoRoot\obj\*.cs" -Recurse)
);
}