Open
Conversation
…OSX tests, mark OSX test as flaky.
.TestParametersWithDatatablesTVPInsert .TestParametersWithSqlRecordsTVPInsert .TestDateOnlyTVPDataTable_CommandSP .TestDateOnlyTVPSqlDataRecord_CommandSP .TestScaledDecimalTCP_CommandSP .ClosedConnection_SqlParameterValueTest_MacOs (split into MacOS and non-MacOS)
Contributor
There was a problem hiding this comment.
Pull request overview
Ports the main-branch “flaky test separation” approach into the 6.0 branch by marking known-flaky tests and updating build/pipeline orchestration so CI runs non-flaky tests first, then runs flaky tests separately while ignoring their failures.
Changes:
- Added
Trait("Category", "flaky")to selected manual/functional tests and split a couple tests by OS so only the problematic OS run is marked flaky. - Updated the
run-all-tests-step.ymltemplate to execute an additional “flaky-only” test pass (--filter category=flaky) withcontinueOnError: true. - Refactored
build.projtest targets to build a reusabledotnet testcommand with shared filter/blame/coverage arguments.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| src/Microsoft.Data.SqlClient/tests/ManualTests/TracingTests/XEventsTracingTest.cs | Marks XEvents tracing theory as flaky via trait. |
| src/Microsoft.Data.SqlClient/tests/ManualTests/TracingTests/DiagnosticTest.cs | Marks DiagnosticTest as flaky via class-level trait. |
| src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/WeakRefTestYukonSpecific/WeakRefTestYukonSpecific.cs | Marks TestReaderMars as flaky via trait. |
| src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/ParameterTest/TvpTest.cs | Marks TVP test as flaky via trait. |
| src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/ParameterTest/ParametersTest.cs | Marks several tests flaky and splits one test into mac/non-mac variants. |
| src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/MARSSessionPoolingTest/MARSSessionPoolingTest.cs | Replaces ActiveIssue skips with flaky categorization. |
| src/Microsoft.Data.SqlClient/tests/ManualTests/SQL/InstanceNameTest/InstanceNameTest.cs | Splits instance-name test into mac/non-mac variants, marking mac as flaky. |
| src/Microsoft.Data.SqlClient.sln | Adds eng/ and pipeline YAMLs as solution items/folders. |
| eng/pipelines/common/templates/steps/run-all-tests-step.yml | Adds separate flaky test runs for functional/manual tests and ignores flaky failures. |
| build.proj | Introduces default filter/coverage/blame args and restructures test targets to use shared command composition. |
| <!-- Collect code coverage unless explicitly disabled --> | ||
| <CollectCodeCoverage Condition="'$(CollectCodeCoverage)' == ''">true</CollectCodeCoverage> | ||
| <CodeCoverageRunSettings>$(TestsPath)/tools/Microsoft.Data.SqlClient.TestUtilities/CodeCoverage.runsettings</CodeCoverageRunSettings> | ||
| <CollectArgument Condition="'$(CollectCodeCoverate)' == 'true'"> |
| <BlameArgument>$(Blame)</BlameArgument> | ||
| <BlameArgument Condition="'$(BlameArgument)' == ''"> | ||
| --blame-hang | ||
| --blame-hang-dump-tup full |
Comment on lines
+212
to
+217
| -v n | ||
| -p:Configuration=$(Configuration) | ||
| -p:Target$(TFGroup)Version=$(TF) | ||
| -p:TestTargetOS=Windows$(TargetGroup) | ||
| -p:ReferenceType=$(ReferenceType) | ||
| $(FilterArgument) |
| -p:Configuration=$(Configuration) | ||
| -p:TargetNetCoreVersion=$(TF) | ||
| -p:TestTargetOS=Unixnetcoreapp | ||
| -p:ReferenceType=$(ReferenceType) |
Comment on lines
+274
to
+275
| <Message Text=">>> Running Functional test for Windows via command: $(TestCommand)" /> | ||
| <Exec ConsoleToMsBuild="true" Command="$(TestCommand)" /> |
| <!-- Convert more than one whitespace character into one space --> | ||
| <TestCommand>$([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " "))</TestCommand> | ||
| </PropertyGroup> | ||
| <Message Text=">>> Running Functional test for Windows via command: $(TestCommand)" /> |
mdaigle
approved these changes
Mar 18, 2026
|
|
||
|
|
||
| [ConditionalFact(typeof(DataTestUtility), nameof(DataTestUtility.IsNotAzureServer), nameof(DataTestUtility.IsNotAzureSynapse), nameof(DataTestUtility.AreConnStringsSetup))] | ||
| [PlatformSpecific(~TestPlatforms.OSX)] |
Contributor
There was a problem hiding this comment.
Didn't know we could use ~ like this for negation. cool!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR ports the flaky test separation from the main branch into the 6.0 branch.
🤖
Codex ported the pipeline changes from main
Testing
Changes mostly apply to pipeline runs, so they will be validated here.