Skip to content

Commit 7a51610

Browse files
committed
fixup! Edit Pipeline Trigger
1 parent f532f03 commit 7a51610

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

.pipelines/templates/run-unit-tests.yaml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@ stages:
5050
ls -la "$REPORT_DIR"
5151
mv coverage-all.out "$COVERAGE_OUT"
5252
ls -la "$REPORT_DIR"
53-
echo "##vso[task.setvariable variable=LINUX_COVERAGE_OUT;isOutput=true]$(cat $REPORT_DIR/linux-coverage.xml)"
53+
echo "##vso[task.setvariable variable=COVERAGE_OUT_XML;isOutput=true]$(cat $REPORT_DIR/linux-coverage.xml)"
54+
name: test_results
5455
retryCountOnTaskFailure: 3
5556
displayName: "Run Unit Tests - Linux"
5657
#workingDirectory: $(ACN_DIR)
@@ -69,7 +70,8 @@ stages:
6970
$GOCOV_BIN convert "$COVERAGE_OUT" > "$REPORT_DIR"/linux-coverage.json
7071
$GOCOV_XML_BIN < "$REPORT_DIR"/linux-coverage.json > "$REPORT_DIR"/linux-coverage.gocov.xml
7172
72-
echo "##vso[task.setvariable variable=LINUX_GOCOV_OUT;isOutput=true]$(cat $REPORT_DIR/linux-coverage.gocov.xml)"
73+
echo "##vso[task.setvariable variable=GOCOV_OUT_XML;isOutput=true]$(cat $REPORT_DIR/linux-coverage.gocov.xml)"
74+
name: report
7375
displayName: "Generate Test Reporting"
7476
#workingDirectory: $(ACN_DIR)
7577
@@ -154,8 +156,9 @@ stages:
154156
# List files in report directory again
155157
Get-ChildItem -Path $env:REPORT_DIR -Force | Select-Object -ExpandProperty FullName | ForEach-Object { Write-Host $_ }
156158
157-
echo "##vso[task.setvariable variable=WIN_COVERAGE_OUT;isOutput=true]$(cat $env:REPORT_DIR/windows-coverage.xml)"
159+
echo "##vso[task.setvariable variable=COVERAGE_OUT_XML;isOutput=true]$(cat $env:REPORT_DIR/windows-coverage.xml)"
158160
retryCountOnTaskFailure: 3
161+
name: test_results
159162
displayName: "Run Unit Tests - Windows"
160163
#workingDirectory: $(ACN_DIR)
161164
@@ -182,7 +185,8 @@ stages:
182185
& Invoke-Expression $env:GOCOV_BIN convert $env:COVERAGE_OUT | Out-File -FilePath (Join-Path -Path $env:REPORT_DIR -ChildPath "windows-coverage.json")
183186
& Invoke-Expression $env:GOCOV_XML_BIN < (Join-Path -Path $env:REPORT_DIR -ChildPath "windows-coverage.json") | Out-File -FilePath (Join-Path -Path $env:REPORT_DIR -ChildPath "windows-coverage.gocov.xml")
184187
185-
echo "##vso[task.setvariable variable=WIN_GOCOV_OUT;isOutput=true]$(cat $env:REPORT_DIR/windows-coverage.gocov.xml)"
188+
echo "##vso[task.setvariable variable=GOCOV_OUT_XML;isOutput=true]$(cat $env:REPORT_DIR/windows-coverage.gocov.xml)"
189+
name: report
186190
displayName: "Generate Test Reporting"
187191
#workingDirectory: $(ACN_DIR)
188192
@@ -207,10 +211,10 @@ stages:
207211
variables:
208212
ob_outputDirectory: $(Build.ArtifactStagingDirectory)/out
209213

210-
LINUX_COVERAGE_OUT: $(LINUX_COVERAGE_OUT)
211-
LINUX_GOCOV_OUT: $(LINUX_GOCOV_OUT)
212-
WIN_COVERAGE_OUT: $(WIN_COVERAGE_OUT)
213-
WIN_GOCOV_OUT: $(WIN_GOCOV_OUT)
214+
WINDOWS_COVERAGE_OUT: $[ dependencies.windows.outputs['test_results.COVERAGE_OUT_XML'] ]
215+
WINDOWS_GOCOV_OUT: $[ dependencies.windows.outputs['report.GOCOV_OUT_XML'] ]
216+
LINUX_COVERAGE_OUT: $[ dependencies.linux.outputs['test_results.COVERAGE_OUT_XML'] ]
217+
LINUX_GOCOV_OUT: $[ dependencies.linux.outputs['report.GOCOV_OUT_XML'] ]
214218
steps:
215219
- script: |
216220
mkdir "$COV_DIR"

0 commit comments

Comments
 (0)