|
1 | 1 | jobs:
|
| 2 | + - job: build |
| 3 | + strategy: |
| 4 | + matrix: |
| 5 | + linux: |
| 6 | + name: 'Linux' |
| 7 | + imageName: 'ubuntu-22.04' |
| 8 | + mac: |
| 9 | + name: 'macOS' |
| 10 | + imageName: 'macOS-latest' |
| 11 | + windows: |
| 12 | + name: 'Windows' |
| 13 | + imageName: 'windows-latest' |
2 | 14 |
|
3 |
| -################################################################################ |
4 |
| -- job: Windows |
5 |
| -################################################################################ |
6 |
| - displayName: Windows |
7 |
| - timeoutInMinutes: 180 |
8 |
| - pool: |
9 |
| - vmImage: windows-latest |
10 |
| - steps: |
11 |
| - - template: eng/steps.yml |
12 |
| - parameters: |
13 |
| - os: 'Windows' |
14 |
| - |
15 |
| -################################################################################ |
16 |
| -- job: Linux |
17 |
| -################################################################################ |
18 |
| - displayName: Linux (Ubuntu) |
19 |
| - timeoutInMinutes: 180 |
20 |
| - pool: |
21 |
| - vmImage: ubuntu-22.04 |
22 |
| - steps: |
23 |
| - - template: eng/steps.yml |
24 |
| - parameters: |
25 |
| - os: 'Linux' |
26 |
| - |
27 |
| -################################################################################ |
28 |
| -- job: macOS |
29 |
| -################################################################################ |
30 |
| - displayName: macOS |
31 |
| - timeoutInMinutes: 180 |
32 |
| - pool: |
33 |
| - vmImage: macOS-latest |
34 |
| - steps: |
35 |
| - - template: eng/steps.yml |
36 |
| - parameters: |
37 |
| - os: 'macOS' |
| 15 | + timeoutInMinutes: 180 |
| 16 | + pool: |
| 17 | + vmImage: $(imageName) |
| 18 | + |
| 19 | + steps: |
| 20 | + - template: eng/steps.yml |
| 21 | + parameters: |
| 22 | + os: $(name) |
| 23 | + |
| 24 | + - job: test |
| 25 | + strategy: |
| 26 | + matrix: |
| 27 | + linux_net462: |
| 28 | + name: Linux |
| 29 | + imageName: ubuntu-22.04 |
| 30 | + framework: net462 |
| 31 | + linux_net6_0: |
| 32 | + name: Linux |
| 33 | + imageName: ubuntu-22.04 |
| 34 | + framework: net6.0 |
| 35 | + linux_net8_0: |
| 36 | + name: Linux |
| 37 | + imageName: ubuntu-22.04 |
| 38 | + framework: net8.0 |
| 39 | + macos_net462: |
| 40 | + name: macOS |
| 41 | + imageName: macOS-latest |
| 42 | + framework: net462 |
| 43 | + macos_net6_0: |
| 44 | + name: macOS |
| 45 | + imageName: macOS-latest |
| 46 | + framework: net6.0 |
| 47 | + macos_net8_0: |
| 48 | + name: macOS |
| 49 | + imageName: macOS-latest |
| 50 | + framework: net8.0 |
| 51 | + windows_net462: |
| 52 | + name: Windows |
| 53 | + imageName: windows-latest |
| 54 | + framework: net462 |
| 55 | + windows_net6_0: |
| 56 | + name: Windows |
| 57 | + imageName: windows-latest |
| 58 | + framework: net6.0 |
| 59 | + windows_net8_0: |
| 60 | + name: Windows |
| 61 | + imageName: windows-latest |
| 62 | + framework: net8.0 |
| 63 | + |
| 64 | + condition: false |
| 65 | + displayName: Test |
| 66 | + timeoutInMinutes: 180 |
| 67 | + pool: |
| 68 | + vmImage: $(imageName) |
| 69 | + |
| 70 | + steps: |
| 71 | + # Prerequisites |
| 72 | + - checkout: self |
| 73 | + submodules: true |
| 74 | + |
| 75 | + # Setup .NET |
| 76 | + - task: UseDotNet@2 |
| 77 | + displayName: Install .NET 6.0 runtime for testing |
| 78 | + inputs: |
| 79 | + packageType: 'runtime' |
| 80 | + version: '6.0.x' |
| 81 | + - task: UseDotNet@2 |
| 82 | + displayName: Install .NET 8.0 runtime for testing |
| 83 | + inputs: |
| 84 | + packageType: 'runtime' |
| 85 | + version: '8.0.x' |
| 86 | + - task: UseDotNet@2 |
| 87 | + displayName: Install .NET 9.0 SDK for build |
| 88 | + inputs: |
| 89 | + packageType: 'sdk' |
| 90 | + version: '9.0.x' |
| 91 | + |
| 92 | + # Build & Test |
| 93 | + - powershell: ./make.ps1 |
| 94 | + displayName: Build |
| 95 | + - powershell: ./make.ps1 -frameworks $(framework) test-all |
| 96 | + displayName: Test ($(framework)) |
| 97 | + |
| 98 | + - task: PublishTestResults@2 |
| 99 | + displayName: Publish Test Results |
| 100 | + inputs: |
| 101 | + testRunner: VSTest |
| 102 | + testResultsFiles: '**/*.trx' |
| 103 | + mergeTestResults: true |
| 104 | + testRunTitle: $(name) - $(framework) |
| 105 | + condition: succeededOrFailed() |
0 commit comments