forked from Ginger-Automation/Ginger
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-linux-pipeline.yml
100 lines (75 loc) · 4.19 KB
/
azure-linux-pipeline.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
jobs:
# ------------------------------------------------------------------------------------------------------
# Request latest Ubunto/Linux
# ------------------------------------------------------------------------------------------------------
- job: Linux
pool:
vmImage: 'ubuntu-latest'
# ------------------------------------------------------------------------------------------------------
# Job Variables
# ------------------------------------------------------------------------------------------------------
variables:
solution: '**/*.sln' # = /home/vsts/work/1/s/Ginger
buildConfiguration: 'Release'
# artifactsFolder: 'D:\a\1\a'
steps:
# ------------------------------------------------------------------------------------------------------
# installs version 3.1.1 latest
# ------------------------------------------------------------------------------------------------------
- task: UseDotNet@2
displayName: 'Use .NET Core sdk 3.1.100'
inputs:
packageType: sdk
version: 3.1.100
installationPath: $(Agent.ToolsDirectory)/dotnet
# ------------------------------------------------------------------------------------------------------
# start Testing
# ------------------------------------------------------------------------------------------------------
- script: dotnet test Ginger/GingerUtilsTest --configuration $(buildConfiguration) --logger trx --verbosity=normal
displayName: 'Testing GingerUtilsTest'
- script: dotnet test Ginger/GingerCoreCommonTest --configuration $(buildConfiguration) --logger trx --verbosity=normal
displayName: 'Testing GingerCoreCommonTest'
# for GingerCoreNET we use run setting to limit to have one worker thread due to workspace limitation
- script: dotnet test Ginger/GingerCoreNETUnitTest --configuration $(buildConfiguration) --logger trx --verbosity=normal
displayName: 'Testing GingerCoreNETUnitTest'
- script: dotnet test Ginger/GingerPluginCoreTest --configuration $(buildConfiguration) --logger trx --verbosity=normal
displayName: 'Testing GingerPluginCoreTest'
- script: dotnet test Ginger/GingerConsoleTest --configuration $(buildConfiguration) --logger trx --verbosity=normal
displayName: 'Testing GingerConsoleTest'
- script: dotnet test Ginger/GingerAutoPilotTest --configuration $(buildConfiguration) --logger trx --verbosity=normal
displayName: 'Testing GingerAutoPilotTest'
# ------------------------------------------------------------------------------------------------------
# Publish GingerConsole
# ------------------------------------------------------------------------------------------------------
- script: dotnet publish Ginger/GingerConsole -c Release
displayName: 'Publish GingerConsole'
# ------------------------------------------------------------------------------------------------------
# Publish Test Results
# ------------------------------------------------------------------------------------------------------
- task: PublishTestResults@2
displayName: Publish test result
condition: succeededOrFailed()
inputs:
testRunner: VSTest
testResultsFiles: '**/*.trx'
# ------------------------------------------------------------------------------------------------------
# Run Standalone CLI Test
# ------------------------------------------------------------------------------------------------------
- task: PowerShell@2
displayName: Run Standalone CLI Test
inputs:
filePath: CLITests.ps1
condition: succeededOrFailed()
# ------------------------------------------------------------------------------------------------------
# Package Test Artifacts
# ------------------------------------------------------------------------------------------------------
- task: PowerShell@2
displayName: Package test artifacts
inputs:
filePath: PackageTestArtifacts.ps1
condition: succeededOrFailed()
# ------------------------------------------------------------------------------------------------------
# Publish Test Artifacts
# ------------------------------------------------------------------------------------------------------
- task: PublishBuildArtifacts@1
condition: succeededOrFailed()