Skip to content

Reduce Azure SQL test scope in PR pipelines - #4609

Draft
saurabh500 wants to merge 2 commits into
mainfrom
dev/saurabh/limit-azure-sql-pr-tests
Draft

saurabh500 wants to merge 2 commits into
mainfrom
dev/saurabh/limit-azure-sql-pr-tests

Conversation

@saurabh500

Copy link
Copy Markdown
Collaborator

Description

Limit Azure SQL Database manual-test legs in all three PR pipelines to:

  • the four connection test classes under SQL/ConnectivityTests
  • the core ManualTests/BulkCopy suite

The required sqlclient-pr pipeline now applies the focused filter to its Azure job. The Package- and Project-reference PR pipelines additionally reduce their Azure SQL matrix from test sets 1/2/3 to set 2, where all selected tests live, while retaining both regular and flaky runs.

Scheduled CI, local SQL Server, LocalDB, named-instance, unit, functional, Always Encrypted, and Azure extension-package coverage are unchanged. Each reference PR pipeline's Azure SQL matrix drops from 51 jobs to 17, removing 68 jobs across the two pipelines.

Issues

N/A

Testing

  • Azure DevOps preview compilation succeeded for sqlclient-pr, PR-SqlClient-Package, and PR-SqlClient-Project from this branch.
  • Expanded PR plans contain 17 Azure SQL jobs per reference pipeline; expanded scheduled CI plans remain at 51 and contain no focused filter.
  • Test discovery with the final set-2 expressions selected 118 regular tests and 1 flaky test.
  • All 10 changed YAML files parse successfully.
  • Live Azure SQL tests were not run locally; PR validation will exercise them.

Guidelines

  • Tests added or updated (pipeline test selection updated; no C# test changes)
  • Public API changes documented (N/A)
  • Verified against customer repro (N/A)
  • Ensure no breaking changes introduced

Please review the contribution guidelines before submitting a pull request:

Run only connectivity and core bulk-copy manual tests against Azure SQL Database in PR pipelines while preserving full scheduled CI coverage.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: a97820b3-c016-4be6-9a0e-37f7e1ef3088
Copilot AI balanced review requested due to automatic review settings August 28, 2026 00:34
@github-project-automation github-project-automation Bot moved this to To triage in SqlClient Board Aug 28, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Focuses Azure SQL manual-test coverage in PR pipelines while preserving full scheduled CI coverage.

Changes:

  • Restricts Azure SQL PR tests to set 2 connectivity and BulkCopy tests.
  • Adds shared regular and flaky test filters.
  • Propagates filters through reusable test templates.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated no comments.

Show a summary per file
File Description
eng/pipelines/sqlclient-pr-project-ref-pipeline.yml Enables focused Azure testing.
eng/pipelines/sqlclient-pr-package-ref-pipeline.yml Enables focused Azure testing.
eng/pipelines/pr/stages/test-stages.yml Applies the focused filter and set 2.
eng/pipelines/pr/sqlclient-pr-pipeline.yml Imports shared filter variables.
eng/pipelines/pr/jobs/test-sqlclientmanual-job.yml Adds manual-test filter support.
eng/pipelines/dotnet-sqlclient-ci-core.yml Conditionally narrows Azure matrices.
eng/pipelines/common/variables/azure-sql-test-filters.yml Defines regular and flaky filters.
eng/pipelines/common/templates/steps/run-all-tests-step.yml Applies filters to manual-test runs.
eng/pipelines/common/templates/stages/ci-run-tests-stage.yml Propagates configuration filters.
eng/pipelines/common/templates/jobs/ci-run-tests-job.yml Forwards filters to test steps.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@saurabh500 saurabh500 added this to the 7.1.0 milestone Aug 28, 2026
Use Windows-compatible double quotes so VSTest receives the intended category expression instead of treating apostrophes as part of the property name.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: a97820b3-c016-4be6-9a0e-37f7e1ef3088
Copilot AI review requested due to automatic review settings August 28, 2026 01:35

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 10 out of 10 changed files in this pull request and generated no new comments.

@paulmedynski paulmedynski left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall I love this! I've mentioned other folks who should review as well. Can we move this out of draft and target 7.1.0?

# VSTest expressions used for regular and quarantined manual-test runs.
- name: manualTestFilters
type: string
default: 'category!=failing&category!=flaky&category!=interactive'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're trying to avoid parameter defaults, and pushing them up the template chain as high as possible. The coalesce()s in ci-run-tests-stage seem like the correct place to keep these values.

targetFramework: ${{ targetFramework }}
netcoreVersionTestUtils: ${{config.value.netcoreVersionTestUtils }}
testSet: ${{ testSet }}
manualTestFilters: ${{ coalesce(config.value.manualTestFilters, 'category!=failing&category!=flaky&category!=interactive') }}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This duplicates the defaults from our C# project files. Should we add a target to build.proj to surface the defaults instead? @benrr101

# Keep Azure SQL PR coverage focused on the connectivity test group and the core BulkCopy suite.
# These tests all belong to manual test set 2.
- name: azureSqlConnectionAndBulkCopyTestsFilter
value: '(FullyQualifiedName~Microsoft.Data.SqlClient.ManualTests.BulkCopy|FullyQualifiedName~Microsoft.Data.SqlClient.ManualTesting.Tests.SqlBulkCopyTests|FullyQualifiedName~Microsoft.Data.SqlClient.ManualTesting.Tests.AADConnectionTest|FullyQualifiedName~Microsoft.Data.SqlClient.ManualTesting.Tests.ConnectionBehaviorTest|FullyQualifiedName~Microsoft.Data.SqlClient.ManualTesting.Tests.ConnectivityTest|FullyQualifiedName~Microsoft.Data.SqlClient.ManualTesting.Tests.TcpDefaultForAzureTest)&category!=failing&category!=flaky&category!=interactive'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@David-Engel @cheenamalhotra - Does this filter cover everything we want to test relatedto Azure SQL for PRs?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Off hand, appears fine to me.

@github-project-automation github-project-automation Bot moved this from To triage to Waiting for customer in SqlClient Board Sep 10, 2026
@paulmedynski paulmedynski added the Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems. label Sep 10, 2026
@cheenamalhotra cheenamalhotra modified the milestones: 7.1.0, 8.0.0-preview1 Sep 10, 2026
@cheenamalhotra

Copy link
Copy Markdown
Member

Overall I love this! I've mentioned other folks who should review as well. Can we move this out of draft and target 7.1.0?

I am working on streamlining it further, and I think 7.1.0 is a short runway considering the release is due next week. I've moved it to next milestone.

@saurabh500

Copy link
Copy Markdown
Collaborator Author

@cheenamalhotra @paulmedynski thanks for finding this useful.
If you want me to push this forward let me know.
I didn't want to distract the team close to release.

@saurabh500

Copy link
Copy Markdown
Collaborator Author

I will wait for Cheena's proposal

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems.

Projects

Status: Waiting for customer

Development

Successfully merging this pull request may close these issues.

7 participants