Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ parameters:
# True to upload code coverage results to CodeCov.
- name: upload
type: boolean
default: true

jobs:
- job: CodeCoverage
Expand Down
19 changes: 19 additions & 0 deletions eng/pipelines/dotnet-sqlclient-ci-core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,25 @@ stages:
image: ADO-MMS22-CodeCov
pool: ${{ parameters.defaultPoolName }}
targetFrameworks: ${{ parameters.codeCovTargetFrameworks }}
# We only want to upload coverage results to CodeCov from certain
# pipelines. We use the pipeline name (Build.DefinitionName) to
# choose. This is a predefined variable that is available at
# template expansion time, so we can use it to supply a true boolean
# value to the upload parameter.
#
# https://learn.microsoft.com/en-us/azure/devops/pipelines/build/variables?view=azure-devops&tabs=yaml#build-variables-devops-services
#
# We're choosing to upload from these pipelines only:
#
# - PR-SqlClient-Project
# - CI-SqlClient
#
# Other pipelines that share this template and use a Project
# buildType don't add much, if any, value to the coverage reports.
# They have not been configured with suitable CodeCov credentials to
# perform the upload.
#
upload: ${{ or(eq(variables['Build.DefinitionName'], 'PR-SqlClient-Project'), eq(variables['Build.DefinitionName'], 'CI-SqlClient')) }}

# test stages configurations
# self hosted SQL Server on Windows
Expand Down
Loading