forked from microsoft/azure-pipelines-agent
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vsts.template.nonwindows.yml
43 lines (36 loc) · 1.11 KB
/
.vsts.template.nonwindows.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
parameters:
componentDetection: 'false'
testLogTitle: 'Non-Windows'
steps:
- ${{ if eq(parameters.componentDetection, 'true') }}:
# Component detection
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
displayName: 'Component Detection'
condition: and(succeeded(), eq(variables['Build.Reason'], 'PullRequest'))
# Clean
- checkout: self
clean: true
# Build agent layout
- script: ./dev.sh layout Release
workingDirectory: src
displayName: Build & Layout Release
# Run test
- script: ./dev.sh test
workingDirectory: src
displayName: Test
# Publish test results
- task: PublishTestResults@2
displayName: Publish Test Results **/*.trx
condition: always()
inputs:
testRunner: VSTest
testResultsFiles: '**/*.trx'
testRunTitle: 'Agent Tests - ${{ parameters.testLogTitle }}'
# Upload test log
- task: PublishBuildArtifacts@1
displayName: Publish Test logs
condition: always()
inputs:
pathToPublish: src/Test/TestLogs
artifactName: ${{ parameters.testLogTitle }}-$(System.JobId)
artifactType: container