-
Notifications
You must be signed in to change notification settings - Fork 335
Expand file tree
/
Copy pathsqlclient-pr-pipeline.yml
More file actions
144 lines (128 loc) · 5.24 KB
/
Copy pathsqlclient-pr-pipeline.yml
File metadata and controls
144 lines (128 loc) · 5.24 KB
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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
#################################################################################
# Licensed to the .NET Foundation under one or more agreements. #
# The .NET Foundation licenses this file to you under the MIT license. #
# See the LICENSE file in the project root for more information. #
#################################################################################
# This pipeline builds and tests all products that we release. It is intended to run as validation
# for every PR. The set of tests it executes is not exhaustive, as many tests require special
# environments to provide complete coverage. Instead, this PR strikes a balance between complete
# confidence and speed of PR validation.
#
# It is triggered by pushes to PRs that target the release/7.1 branch in GitHub.
#
# It maps to the "sqlclient-pr" pipeline in the Public ADO project:
# https://sqlclientdrivers.visualstudio.com/public/_build?definitionId=2281
# And the "sqlclient-pr" pipeline in the internal ADO project:
# https://dev.azure.com/SqlClientDrivers/ADO.Net/_build?definitionId=2271
# Set the pipeline run name to the day-of-year and the daily run counter.
name: $(DayOfYear)$(Rev:rr)
# Trigger PR validation runs for all pushes to PRs that target the specified branches.
# https://learn.microsoft.com/en-us/azure/devops/pipelines/repos/github?view=azure-devops&tabs=yaml#pr-triggers
pr:
branches:
include:
- release/7.1-staging
paths:
include:
- .azuredevops/*
- .config/*
- doc/*
- eng/pipelines/common/*
- eng/pipelines/pr/*
- src/*
- tools/*
- azurepipelines-coverage.yml
- build.proj
- Directory.Packages.props
- dotnet-tools.json
- global.json
- NuGet.config
# Do not trigger commit or schedule runs for this pipeline.
trigger: none
parameters:
# General Parameters =====================================================
# Dotnet CLI verbosity level.
- name: dotnetVerbosity
displayName: dotnet CLI Verbosity
type: string
default: normal
values:
- quiet
- minimal
- normal
- detailed
- diagnostic
- name: platforms
type: object
default:
- displayName: "windows_net462"
dotnet: "net462"
image: "ADO-MMS25-SQL25"
operatingSystem: "Windows"
- displayName: "windows_net8"
dotnet: "net8.0"
image: "ADO-MMS25-SQL25"
operatingSystem: "Windows"
- displayName: "windows_net9"
dotnet: "net9.0"
image: "ADO-MMS25-SQL25"
operatingSystem: "Windows"
- displayName: "windows_net10"
dotnet: "net10.0"
image: "ADO-MMS25-SQL25"
operatingSystem: "Windows"
- displayName: "linux_net8"
dotnet: "net8.0"
image: "ADO-UB24-SQL25"
operatingSystem: "Linux"
- displayName: "linux_net9"
dotnet: "net9.0"
image: "ADO-UB24-SQL25"
operatingSystem: "Linux"
- displayName: "linux_net10"
dotnet: "net10.0"
image: "ADO-UB24-SQL25"
operatingSystem: "Linux"
variables:
- template: /eng/pipelines/common/variables/common-variables.yml@self
- template: /eng/pipelines/pr/variables/pr-variables.yml@self
stages:
# Stage 1a: Build and pack all projects in the repository
- template: /eng/pipelines/pr/stages/pack-stage.yml@self
parameters:
buildConfiguration: Debug
buildSuffix: pr
stageName: ${{ variables.stageNamePack }}
packArtifactBaseName: ${{ variables.packArtifactBaseName }}
# Stage 1b: Generate secrets
- template: /eng/pipelines/pr/stages/generate-secrets-stage.yml@self
parameters:
stageName: ${{ variables.stageNameSecrets }}
# Stage 2: Execute tests and collect code coverage
- template: /eng/pipelines/pr/stages/test-stages.yml@self
parameters:
buildConfiguration: Debug
buildSuffix: pr
dotnetVerbosity: ${{ parameters.dotnetVerbosity }}
poolName: $(PoolNameDefault)
stageNamePack: ${{ variables.stageNamePack }}
stageNameSecrets: ${{ variables.stageNameSecrets }}
testResultsArtifactBaseName: ${{ variables.testResultsArtifactBaseName }}
platforms: ${{ parameters.platforms }}
manualTestAzureKeyVaultUrl: $(AzureKeyVaultUrl)
manualTestAzureKeyVaultTenantId: $(AzureKeyVaultTenantId)
manualTestConnectionStringNpLocalhost: $(ConnectionStringNp_LocalhostDefault_UsernamePassword)
manualTestConnectionStringTcpLocalhost: $(ConnectionStringTcp_LocalhostDefault_UsernamePassword)
manualTestConnectionStringNpAzure: $(ConnectionStringNp_Azure_ManagedIdentity)
manualTestConnectionStringTcpAzure: $(ConnectionStringTcp_Azure_ManagedIdentity)
manualTestFileStreamDirectory: "$(Pipeline.Workspace)/filestream"
manualTestLocalDbAppName: $(LocalDbAppName)
manualTestLocalDbSharedInstanceName: $(LocalDbSharedInstanceName)
manualTestUserManagedIdentityClientId: $(UserManagedIdentityClientId)
# Stage 3: Collect code coverage
- template: /eng/pipelines/pr/stages/collect-coverage-stage.yml@self
parameters:
coverageArtifactBaseName: ${{ variables.coverageArtifactBaseName }}
dependsOn:
- ${{ each platform in parameters.platforms }}:
- "test_${{ platform.displayName }}"