From ecdbdb04522ba0ddd75dd3d2f8940ab19a15cc5e Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Tue, 3 Feb 2026 16:18:13 -0600 Subject: [PATCH 01/18] Cleanup AKV provider project file --- ...waysEncrypted.AzureKeyVaultProvider.csproj | 56 +++++++++++-------- 1 file changed, 32 insertions(+), 24 deletions(-) diff --git a/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj b/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj index 31f6b3fcb1..067f514707 100644 --- a/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj +++ b/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj @@ -1,40 +1,48 @@  - Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider - AzureKeyVaultProvider - {9073ABEF-92E0-4702-BB23-2C99CEF9BDD7} - netcoreapp - netfx - Debug;Release; - AnyCPU;x86;x64 - $(ObjFolder)$(Configuration).$(Platform)\$(AddOnName) - $(BinFolder)$(Configuration).$(Platform)\$(AddOnName) - $(BinFolder)$(Configuration).$(Platform)\$(AssemblyName).xml - - false + Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider MIT true - true - true - - - true - $(SigningKeyPath) + + + + + $(BinFolder)$(Configuration).$(Platform)\AzureKeyVaultProvider + $(ObjFolder)$(Configuration).$(Platform)\AzureKeyVaultProvider + $(BinFolder)$(Configuration).$(Platform)\$(AssemblyName).xml + + + + true + true + + + $(SigningKeyPath) + + true + $(SigningKeyPath) + + + + - - - - - - + + + + + + From a38293cb6f78f2d96681ce57c78fdafed7e51b27 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Wed, 4 Feb 2026 18:25:16 -0600 Subject: [PATCH 02/18] Point AKV provider at common MDS project --- ...SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj b/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj index 067f514707..f173c4ea01 100644 --- a/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj +++ b/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj @@ -32,14 +32,10 @@ - - - + - From 88f53cabb5a37e3929d59155d7322c4bc88cf4e7 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 16:18:40 -0600 Subject: [PATCH 03/18] Point custom retry logic provider at common MDS --- .../CustomRetryLogicProvider.csproj | 24 ++++++------------- 1 file changed, 7 insertions(+), 17 deletions(-) diff --git a/src/Microsoft.Data.SqlClient/tests/CustomConfigurableRetryLogic/CustomRetryLogicProvider.csproj b/src/Microsoft.Data.SqlClient/tests/CustomConfigurableRetryLogic/CustomRetryLogicProvider.csproj index f420579f9e..f3f45a0a65 100644 --- a/src/Microsoft.Data.SqlClient/tests/CustomConfigurableRetryLogic/CustomRetryLogicProvider.csproj +++ b/src/Microsoft.Data.SqlClient/tests/CustomConfigurableRetryLogic/CustomRetryLogicProvider.csproj @@ -1,24 +1,14 @@  + ExternalConfigurableRetryLogic - netfx - netcoreapp - false - $(ObjFolder)$(Configuration).$(Platform).$(AssemblyName) - $(BinFolder)$(Configuration).$(Platform).$(AssemblyName) - - - - - - - - - - - - + + + + From 3a799e75fa52cc1952f603706037c1af3e7e0c7d Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 16:22:24 -0600 Subject: [PATCH 04/18] Point manual tests against CommonTest and Common MDS projects. --- .../Microsoft.Data.SqlClient.ManualTests.csproj | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/Microsoft.Data.SqlClient/tests/ManualTests/Microsoft.Data.SqlClient.ManualTests.csproj b/src/Microsoft.Data.SqlClient/tests/ManualTests/Microsoft.Data.SqlClient.ManualTests.csproj index 3e2c30014d..5340f63a9d 100644 --- a/src/Microsoft.Data.SqlClient/tests/ManualTests/Microsoft.Data.SqlClient.ManualTests.csproj +++ b/src/Microsoft.Data.SqlClient/tests/ManualTests/Microsoft.Data.SqlClient.ManualTests.csproj @@ -300,15 +300,13 @@ - - - + + @@ -342,7 +340,7 @@ - + @@ -375,7 +373,7 @@ - + From 97580fba3fc120cf0a5bcd2678b14b9fb2b0edb4 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 16:29:06 -0600 Subject: [PATCH 05/18] Remove BuildManualTests* build.proj targets - they are no longer necessary --- build.proj | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) diff --git a/build.proj b/build.proj index a89c86d974..8a9213ee6a 100644 --- a/build.proj +++ b/build.proj @@ -102,8 +102,12 @@ - - + + + + + + @@ -256,24 +260,6 @@ - - - - - - - - - - - - - - - - - - From 901454856f1dc8f73b6b8959c2bf265f3c12b16f Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 16:34:55 -0600 Subject: [PATCH 06/18] RunManualTests* build.proj targets now build the project and dependencies --- build.proj | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/build.proj b/build.proj index 8a9213ee6a..d0374966c1 100644 --- a/build.proj +++ b/build.proj @@ -80,17 +80,6 @@ - - - - - - - - - - - @@ -369,13 +358,10 @@ $(DotnetPath)dotnet test "@(ManualTestsProj)" - --no-build - -v n + -f $(TF) -p:Configuration=$(Configuration) - -p:Target$(TFGroup)Version=$(TF) -p:ReferenceType=$(ReferenceType) -p:TestSet=$(TestSet) - -p:TestTargetOS=Windows$(TargetGroup) $(CollectStatement) --results-directory $(ResultsDirectory) --filter "$(FilterStatement)" @@ -395,13 +381,10 @@ $(DotnetPath)dotnet test "@(ManualTestsProj)" - --no-build - -v n + -f $(TF) -p:Configuration=$(Configuration) - -p:TargetNetCoreVersion=$(TF) -p:ReferenceType=$(ReferenceType) -p:TestSet=$(TestSet) - -p:TestTargetOS=Unixnetcoreapp $(CollectStatement) --results-directory $(ResultsDirectory) --filter "$(FilterStatement)" From 1361d3e4c96b824cf88b18dbafd3321451eb170d Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 16:56:15 -0600 Subject: [PATCH 07/18] Cleanup filter/collect/blame arguments for test targets, ensure test set is only set if provided. --- build.proj | 90 ++++++++++++++++++++++++++++++------------------------ 1 file changed, 50 insertions(+), 40 deletions(-) diff --git a/build.proj b/build.proj index d0374966c1..9b659c9cab 100644 --- a/build.proj +++ b/build.proj @@ -49,11 +49,21 @@ - $(Filter) - category!=failing&category!=flaky - - true - --collect "Code coverage" + + category!=failing&category!=flaky + --filter "$(Filter)" + + + true + --collect "Code coverage" + + + $(Blame) + + --blame-hang + --blame-hang-dump-type full + --blame-hang-timeout 10m + @@ -264,13 +274,11 @@ $(DotnetPath)dotnet test "@(UnitTestsProj)" -f $(TF) -p:Configuration=$(Configuration) - $(CollectStatement) + $(FilterArgument) + $(BlameArgument) + $(CollectArgument) --results-directory $(ResultsDirectory) - --filter "$(FilterStatement)" --logger:"trx;LogFilePrefix=Unit-Windows$(TargetGroup)-$(TestSet)" - --blame-hang - --blame-hang-dump-type full - --blame-hang-timeout 10m $([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " ")) @@ -286,13 +294,11 @@ $(DotnetPath)dotnet test "@(UnitTestsProj)" -f $(TF) -p:Configuration=$(Configuration) - $(CollectStatement) + $(FilterArgument) + $(BlameArgument) + $(CollectArgument) --results-directory $(ResultsDirectory) - --filter "$(FilterStatement)" --logger:"trx;LogFilePrefix=Unit-Unixnetcoreapp-$(TestSet)" - --blame-hang - --blame-hang-dump-type full - --blame-hang-timeout 10m $([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " ")) @@ -312,13 +318,11 @@ -f $(TF) -p:Configuration=$(Configuration) -p:ReferenceType=$(ReferenceType) - $(CollectStatement) + $(FilterArgument) + $(BlameArgument) + $(CollectArgument) --results-directory $(ResultsDirectory) - --filter "$(FilterStatement)" --logger:"trx;LogFilePrefix=Functional-Windows$(TargetGroup)-$(TestSet)" - --blame-hang - --blame-hang-dump-type full - --blame-hang-timeout 10m $([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " ")) @@ -335,13 +339,11 @@ -f $(TF) -p:Configuration=$(Configuration) -p:ReferenceType=$(ReferenceType) - $(CollectStatement) + $(FilterArgument) + $(BlameArgument) + $(CollectArgument) --results-directory $(ResultsDirectory) - --filter "$(FilterStatement)" --logger:"trx;LogFilePrefix=Functional-Unixnetcoreapp-$(TestSet)" - --blame-hang - --blame-hang-dump-type full - --blame-hang-timeout 10m $([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " ")) @@ -361,16 +363,20 @@ -f $(TF) -p:Configuration=$(Configuration) -p:ReferenceType=$(ReferenceType) - -p:TestSet=$(TestSet) - $(CollectStatement) + $(FilterArgument) + $(BlameArgument) + $(CollectArgument) --results-directory $(ResultsDirectory) - --filter "$(FilterStatement)" --logger:"trx;LogFilePrefix=Manual-Windows$(TargetGroup)-$(TestSet)" - --blame-hang - --blame-hang-dump-type full - --blame-hang-timeout 10m - $(TestCommand.Replace($([System.Environment]::NewLine), " ")) + + + $(TestCommand) + -p:TestSet=$(TestSet) + + + + $([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " ")) @@ -384,18 +390,22 @@ -f $(TF) -p:Configuration=$(Configuration) -p:ReferenceType=$(ReferenceType) - -p:TestSet=$(TestSet) - $(CollectStatement) + $(FilterArgument) + $(BlameArgument) + $(CollectArgument) --results-directory $(ResultsDirectory) - --filter "$(FilterStatement)" --logger:"trx;LogFilePrefix=Manual-Unixnetcoreapp-$(TestSet)" - --blame-hang - --blame-hang-dump-type full - --blame-hang-timeout 10m - $(TestCommand.Replace($([System.Environment]::NewLine), " ")) + + + + $(TestCommand) + -p:TestSet=$(TestSet) + + + + $([System.Text.RegularExpressions.Regex]::Replace($(TestCommand), "\s+", " ")) - From 8c33e241288ed20c9cbfa77d9a74bb4b7dac5e20 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 17:00:00 -0600 Subject: [PATCH 08/18] Remove BuildTests* targets from build.proj, remove from pipelines. --- build.proj | 8 ---- .../templates/steps/build-all-tests-step.yml | 48 +------------------ .../build-and-run-tests-netcore-step.yml | 12 ----- .../steps/build-and-run-tests-netfx-step.yml | 12 ----- 4 files changed, 1 insertion(+), 79 deletions(-) diff --git a/build.proj b/build.proj index 9b659c9cab..0924c020e5 100644 --- a/build.proj +++ b/build.proj @@ -100,14 +100,6 @@ - - - - - - - - $(CommonProperties) diff --git a/eng/pipelines/common/templates/steps/build-all-tests-step.yml b/eng/pipelines/common/templates/steps/build-all-tests-step.yml index c8a090c3ff..a0fb86bd71 100644 --- a/eng/pipelines/common/templates/steps/build-all-tests-step.yml +++ b/eng/pipelines/common/templates/steps/build-all-tests-step.yml @@ -35,50 +35,4 @@ parameters: type: string steps: -- ${{ if contains(parameters.targetFramework, 'net4') }}: # .NET Framework - - task: MSBuild@1 - displayName: 'Build Tests NetFx' - inputs: - solution: build.proj - platform: '${{ parameters.platform }}' - configuration: '${{ parameters.buildConfiguration }}' - msbuildArguments: >- - -t:BuildTestsNetFx - -p:TF=${{ parameters.targetFramework }} - -p:TestSet=${{ parameters.testSet }} - -p:ReferenceType=${{ parameters.referenceType }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} -- ${{elseif eq(parameters.osGroup, '')}}: # .NET on Windows - - task: MSBuild@1 - displayName: 'Build Tests NetCore [Win]' - inputs: - solution: build.proj - platform: '${{ parameters.platform }}' - configuration: '${{ parameters.buildConfiguration }}' - msbuildArguments: >- - -t:BuildTestsNetCore - -p:TF=${{ parameters.targetFramework }} - -p:TestSet=${{ parameters.testSet }} - -p:ReferenceType=${{ parameters.referenceType }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} - condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT')) - -- ${{ else }}: # .NET on Unix - - task: DotNetCoreCLI@2 - displayName: 'Build Tests NetCore [Non-Win]' - inputs: - command: custom - projects: build.proj - custom: msbuild - arguments: >- - -t:BuildTestsNetCore - -p:TF=${{ parameters.targetFramework }} - -p:TestSet=${{ parameters.testSet }} - -p:ReferenceType=${{ parameters.referenceType }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} - -p:OSGroup=${{ parameters.osGroup }} - -p:platform=${{ parameters.platform }} - -p:Configuration=${{ parameters.buildConfiguration }} - verbosityRestore: Detailed - verbosityPack: Detailed - condition: and(succeeded(), ne(variables['Agent.OS'], 'Windows_NT')) + # Nothing to do! diff --git a/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml b/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml index 37a0cf87f6..956cfdc28b 100644 --- a/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml +++ b/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml @@ -52,18 +52,6 @@ steps: -p:ReferenceType=${{ parameters.referenceType }} -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} -- task: MSBuild@1 - displayName: 'MSBuild Build Tests for ${{parameters.TargetNetCoreVersion }}' - inputs: - solution: build.proj - msbuildArchitecture: x64 - msbuildArguments: >- - -t:BuildTestsNetCore - -p:ReferenceType=${{ parameters.referenceType }} - -p:TargetNetCoreVersion=${{ parameters.TargetNetCoreVersion }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} - -p:Configuration=${{ parameters.buildConfiguration }} - # Don't run unit tests using package reference. Unit tests are only run using project reference. - task: DotNetCoreCLI@2 diff --git a/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml b/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml index ba1d247fee..443ca99687 100644 --- a/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml +++ b/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml @@ -52,18 +52,6 @@ steps: -p:ReferenceType=${{ parameters.referenceType }} -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} -- task: MSBuild@1 - displayName: 'MSBuild Build Tests for ${{parameters.TargetNetFxVersion }}' - inputs: - solution: build.proj - msbuildArguments: >- - -t:BuildTestsNetFx - -p:ReferenceType=${{ parameters.referenceType }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} - -p:TargetNetFxVersion=${{ parameters.TargetNetFxVersion }} - -p:Configuration=${{ parameters.buildConfiguration }} - -p:Platform=${{ parameters.platform }} - # Don't run unit tests using package reference. Unit tests are only run using project reference. - task: DotNetCoreCLI@2 From a6d99324ae2612674cc25509d552c4c645c12aec Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 17:06:20 -0600 Subject: [PATCH 09/18] Drop build-all-tests-step.yml since it no longer does anything --- .../templates/jobs/ci-run-tests-job.yml | 10 ----- .../templates/steps/build-all-tests-step.yml | 38 ------------------- src/Microsoft.Data.SqlClient.sln | 1 - 3 files changed, 49 deletions(-) delete mode 100644 eng/pipelines/common/templates/steps/build-all-tests-step.yml diff --git a/eng/pipelines/common/templates/jobs/ci-run-tests-job.yml b/eng/pipelines/common/templates/jobs/ci-run-tests-job.yml index 02cc6d58de..64c252773e 100644 --- a/eng/pipelines/common/templates/jobs/ci-run-tests-job.yml +++ b/eng/pipelines/common/templates/jobs/ci-run-tests-job.yml @@ -265,16 +265,6 @@ jobs: ${{ if parameters.configProperties.FileStreamDirectory }}: fileStreamDirectory: ${{ parameters.configProperties.FileStreamDirectory }} - - template: /eng/pipelines/common/templates/steps/build-all-tests-step.yml@self # build tests - parameters: - targetFramework: ${{ parameters.targetFramework }} - buildConfiguration: ${{ parameters.buildConfiguration }} - referenceType: ${{ parameters.referenceType }} - testSet: ${{ parameters.testSet }} - mdsPackageVersion: ${{ parameters.mdsPackageVersion }} - ${{ if ne(parameters.operatingSystem, 'Windows') }}: - OSGroup: Unix - - ${{ if eq(parameters.enableX64Test, true) }}: # run native tests - template: /eng/pipelines/common/templates/steps/run-all-tests-step.yml@self # run tests parameters: diff --git a/eng/pipelines/common/templates/steps/build-all-tests-step.yml b/eng/pipelines/common/templates/steps/build-all-tests-step.yml deleted file mode 100644 index a0fb86bd71..0000000000 --- a/eng/pipelines/common/templates/steps/build-all-tests-step.yml +++ /dev/null @@ -1,38 +0,0 @@ -################################################################################# -# 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. # -################################################################################# -parameters: - - - name: buildConfiguration - type: string - values: - - Debug - - Release - - - name: mdsPackageVersion - type: string - - - name: osGroup - type: string - default: '' - - - name: platform - type: string - default: $(Platform) - - - name: referenceType - type: string - values: - - Project - - Package - - - name: targetFramework - type: string - - - name: testSet - type: string - -steps: - # Nothing to do! diff --git a/src/Microsoft.Data.SqlClient.sln b/src/Microsoft.Data.SqlClient.sln index adcb5de38e..036028aad6 100644 --- a/src/Microsoft.Data.SqlClient.sln +++ b/src/Microsoft.Data.SqlClient.sln @@ -245,7 +245,6 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "steps", "steps", "{EABE3A3E-D505-418A-B1B8-1B0AC4872F3D}" ProjectSection(SolutionItems) = preProject ..\eng\pipelines\common\templates\steps\build-all-configurations-signed-dlls-step.yml = ..\eng\pipelines\common\templates\steps\build-all-configurations-signed-dlls-step.yml - ..\eng\pipelines\common\templates\steps\build-all-tests-step.yml = ..\eng\pipelines\common\templates\steps\build-all-tests-step.yml ..\eng\pipelines\common\templates\steps\build-and-run-tests-netcore-step.yml = ..\eng\pipelines\common\templates\steps\build-and-run-tests-netcore-step.yml ..\eng\pipelines\common\templates\steps\build-and-run-tests-netfx-step.yml = ..\eng\pipelines\common\templates\steps\build-and-run-tests-netfx-step.yml ..\eng\pipelines\common\templates\steps\ci-prebuild-step.yml = ..\eng\pipelines\common\templates\steps\ci-prebuild-step.yml From 1ecb6c0aa5b85a5699bbd80384999b38f9507749 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 17:13:35 -0600 Subject: [PATCH 10/18] Remove AKV build from before test execution - it is now built as a dependency for manual tests. --- .../steps/build-and-run-tests-netcore-step.yml | 10 ---------- .../templates/steps/build-and-run-tests-netfx-step.yml | 10 ---------- 2 files changed, 20 deletions(-) diff --git a/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml b/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml index 956cfdc28b..7b5cc9cd73 100644 --- a/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml +++ b/eng/pipelines/common/templates/steps/build-and-run-tests-netcore-step.yml @@ -41,16 +41,6 @@ parameters: default: 2 steps: -- task: MSBuild@1 - displayName: 'Build AKV Provider .NET' - inputs: - solution: build.proj - msbuildArchitecture: x64 - msbuildArguments: >- - -p:Configuration=${{ parameters.buildConfiguration }} - -t:BuildAKVNetCore - -p:ReferenceType=${{ parameters.referenceType }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} # Don't run unit tests using package reference. Unit tests are only run using project reference. diff --git a/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml b/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml index 443ca99687..29d41002e4 100644 --- a/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml +++ b/eng/pipelines/common/templates/steps/build-and-run-tests-netfx-step.yml @@ -41,16 +41,6 @@ parameters: default: 2 steps: -- task: MSBuild@1 - displayName: 'Build AKV Provider .NET Framework' - inputs: - solution: build.proj - msbuildArchitecture: x64 - msbuildArguments: >- - -p:Configuration=${{ parameters.buildConfiguration }} - -t:BuildAKVNetFx - -p:ReferenceType=${{ parameters.referenceType }} - -p:MdsPackageVersion=${{ parameters.mdsPackageVersion }} # Don't run unit tests using package reference. Unit tests are only run using project reference. From d67226f23c6a1935800f611708e0d744f995b7d4 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 17:16:56 -0600 Subject: [PATCH 11/18] Remove manual tests from the restoretests* targets --- build.proj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build.proj b/build.proj index 0924c020e5..c5b9b4f3bd 100644 --- a/build.proj +++ b/build.proj @@ -195,7 +195,7 @@ - + @@ -203,7 +203,7 @@ - + From f968fa7bb26a20a0675ea780cc281c655098f4ad Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 17:18:35 -0600 Subject: [PATCH 12/18] Remove RestoreTests* targets as they were doing nothing and not being used anywhere --- build.proj | 8 -------- 1 file changed, 8 deletions(-) diff --git a/build.proj b/build.proj index c5b9b4f3bd..73de003509 100644 --- a/build.proj +++ b/build.proj @@ -194,18 +194,10 @@ - - - - - - - - From 65e3f6c85e656ca65cf5c14caae8a97c2b8829cf Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 17:49:15 -0600 Subject: [PATCH 13/18] Someone didn't add their new pipeline files to the solution... tsk tsk :wink: --- src/Microsoft.Data.SqlClient.sln | 29 +++++++++++++++++++++++------ 1 file changed, 23 insertions(+), 6 deletions(-) diff --git a/src/Microsoft.Data.SqlClient.sln b/src/Microsoft.Data.SqlClient.sln index 036028aad6..e28112aa46 100644 --- a/src/Microsoft.Data.SqlClient.sln +++ b/src/Microsoft.Data.SqlClient.sln @@ -213,6 +213,10 @@ EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Data.SqlClient", "Microsoft.Data.SqlClient\src\Microsoft.Data.SqlClient.csproj", "{9A8996A8-6484-4AA7-B50F-F861430EDE2F}" EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "eng", "eng", "{4600328C-C134-499F-AAE2-964E8AD5472C}" + ProjectSection(SolutionItems) = preProject + ..\build.proj = ..\build.proj + ..\build2.proj = ..\build2.proj + EndProjectSection EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "pipelines", "pipelines", "{4CAE9195-4F1A-4D48-854C-1C9FBC512C66}" ProjectSection(SolutionItems) = preProject @@ -221,6 +225,9 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "pipelines", "pipelines", "{ ..\eng\pipelines\dotnet-sqlclient-ci-package-reference-pipeline.yml = ..\eng\pipelines\dotnet-sqlclient-ci-package-reference-pipeline.yml ..\eng\pipelines\dotnet-sqlclient-ci-project-reference-pipeline.yml = ..\eng\pipelines\dotnet-sqlclient-ci-project-reference-pipeline.yml ..\eng\pipelines\dotnet-sqlclient-signing-pipeline.yml = ..\eng\pipelines\dotnet-sqlclient-signing-pipeline.yml + ..\eng\pipelines\sqlclient-pr-package-ref-pipeline.yml = ..\eng\pipelines\sqlclient-pr-package-ref-pipeline.yml + ..\eng\pipelines\sqlclient-pr-project-ref-pipeline.yml = ..\eng\pipelines\sqlclient-pr-project-ref-pipeline.yml + ..\eng\pipelines\stress-tests-pipeline.yml = ..\eng\pipelines\stress-tests-pipeline.yml EndProjectSection EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "common", "common", "{FD4D7A96-79B1-4F89-B64D-29FACCC9232F}" @@ -247,7 +254,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "steps", "steps", "{EABE3A3E ..\eng\pipelines\common\templates\steps\build-all-configurations-signed-dlls-step.yml = ..\eng\pipelines\common\templates\steps\build-all-configurations-signed-dlls-step.yml ..\eng\pipelines\common\templates\steps\build-and-run-tests-netcore-step.yml = ..\eng\pipelines\common\templates\steps\build-and-run-tests-netcore-step.yml ..\eng\pipelines\common\templates\steps\build-and-run-tests-netfx-step.yml = ..\eng\pipelines\common\templates\steps\build-and-run-tests-netfx-step.yml - ..\eng\pipelines\common\templates\steps\ci-prebuild-step.yml = ..\eng\pipelines\common\templates\steps\ci-prebuild-step.yml ..\eng\pipelines\common\templates\steps\ci-project-build-step.yml = ..\eng\pipelines\common\templates\steps\ci-project-build-step.yml ..\eng\pipelines\common\templates\steps\code-analyze-step.yml = ..\eng\pipelines\common\templates\steps\code-analyze-step.yml ..\eng\pipelines\common\templates\steps\configure-sql-server-linux-step.yml = ..\eng\pipelines\common\templates\steps\configure-sql-server-linux-step.yml @@ -264,7 +270,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "steps", "steps", "{EABE3A3E ..\eng\pipelines\common\templates\steps\publish-test-results-step.yml = ..\eng\pipelines\common\templates\steps\publish-test-results-step.yml ..\eng\pipelines\common\templates\steps\run-all-tests-step.yml = ..\eng\pipelines\common\templates\steps\run-all-tests-step.yml ..\eng\pipelines\common\templates\steps\update-config-file-step.yml = ..\eng\pipelines\common\templates\steps\update-config-file-step.yml - ..\eng\pipelines\common\templates\steps\update-nuget-config-local-feed-step.yml = ..\eng\pipelines\common\templates\steps\update-nuget-config-local-feed-step.yml EndProjectSection EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "libraries", "libraries", "{75BAE755-3A1F-41F2-9176-9F8FF9FEE2DD}" @@ -288,21 +293,25 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "jobs", "jobs", "{09352F1D-878F-4F55-8AA2-6E47F1AD37D5}" ProjectSection(SolutionItems) = preProject ..\eng\pipelines\jobs\build-akv-official-job.yml = ..\eng\pipelines\jobs\build-akv-official-job.yml + ..\eng\pipelines\jobs\pack-abstractions-package-ci-job.yml = ..\eng\pipelines\jobs\pack-abstractions-package-ci-job.yml + ..\eng\pipelines\jobs\pack-azure-package-ci-job.yml = ..\eng\pipelines\jobs\pack-azure-package-ci-job.yml ..\eng\pipelines\jobs\stress-tests-ci-job.yml = ..\eng\pipelines\jobs\stress-tests-ci-job.yml + ..\eng\pipelines\jobs\test-abstractions-package-ci-job.yml = ..\eng\pipelines\jobs\test-abstractions-package-ci-job.yml + ..\eng\pipelines\jobs\test-azure-package-ci-job.yml = ..\eng\pipelines\jobs\test-azure-package-ci-job.yml EndProjectSection EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "steps", "steps", "{AD738BD4-6A02-4B88-8F93-FBBBA49A74C8}" ProjectSection(SolutionItems) = preProject ..\eng\pipelines\steps\compound-build-akv-step.yml = ..\eng\pipelines\steps\compound-build-akv-step.yml + ..\eng\pipelines\steps\compound-esrp-dll-signing-step.yml = ..\eng\pipelines\steps\compound-esrp-dll-signing-step.yml + ..\eng\pipelines\steps\compound-esrp-nuget-signing-step.yml = ..\eng\pipelines\steps\compound-esrp-nuget-signing-step.yml ..\eng\pipelines\steps\compound-extract-akv-apiscan-files-step.yml = ..\eng\pipelines\steps\compound-extract-akv-apiscan-files-step.yml ..\eng\pipelines\steps\compound-nuget-pack-step.yml = ..\eng\pipelines\steps\compound-nuget-pack-step.yml ..\eng\pipelines\steps\compound-publish-symbols-step.yml = ..\eng\pipelines\steps\compound-publish-symbols-step.yml - ..\eng\pipelines\steps\roslyn-analyzers-akv-step.yml = ..\eng\pipelines\steps\roslyn-analyzers-akv-step.yml - ..\eng\pipelines\steps\script-output-environment-variables-step.yml = ..\eng\pipelines\steps\script-output-environment-variables-step.yml ..\eng\pipelines\steps\install-dotnet.yml = ..\eng\pipelines\steps\install-dotnet.yml ..\eng\pipelines\steps\install-dotnet-arm64.ps1 = ..\eng\pipelines\steps\install-dotnet-arm64.ps1 - ..\eng\pipelines\steps\compound-esrp-dll-signing-step.yml = ..\eng\pipelines\steps\compound-esrp-dll-signing-step.yml - ..\eng\pipelines\steps\compound-esrp-nuget-signing-step.yml = ..\eng\pipelines\steps\compound-esrp-nuget-signing-step.yml + ..\eng\pipelines\steps\roslyn-analyzers-akv-step.yml = ..\eng\pipelines\steps\roslyn-analyzers-akv-step.yml + ..\eng\pipelines\steps\script-output-environment-variables-step.yml = ..\eng\pipelines\steps\script-output-environment-variables-step.yml EndProjectSection EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Data.SqlClient.UnitTests", "Microsoft.Data.SqlClient\tests\UnitTests\Microsoft.Data.SqlClient.UnitTests.csproj", "{4461063D-2F2B-274C-7E6F-F235119D258E}" @@ -355,6 +364,13 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tools", "tools", "{134A5E42 EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{2B71F605-037E-5629-6E23-0FA3C297446D}" EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "stages", "stages", "{E9D12AEC-2F11-4871-89BB-343BF1CAEA4C}" + ProjectSection(SolutionItems) = preProject + ..\eng\pipelines\stages\build-abstractions-package-ci-stage.yml = ..\eng\pipelines\stages\build-abstractions-package-ci-stage.yml + ..\eng\pipelines\stages\build-azure-package-ci-stage.yml = ..\eng\pipelines\stages\build-azure-package-ci-stage.yml + ..\eng\pipelines\stages\stress-tests-ci-stage.yml = ..\eng\pipelines\stages\stress-tests-ci-stage.yml + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -826,6 +842,7 @@ Global {7E0602AC-7F0A-362A-D734-0FDDFCC600B5} = {7289C27E-D7DF-2C71-84B4-151F3A162493} {134A5E42-015B-3575-2B2B-722614F4C835} = {7E0602AC-7F0A-362A-D734-0FDDFCC600B5} {2B71F605-037E-5629-6E23-0FA3C297446D} = {7289C27E-D7DF-2C71-84B4-151F3A162493} + {E9D12AEC-2F11-4871-89BB-343BF1CAEA4C} = {4CAE9195-4F1A-4D48-854C-1C9FBC512C66} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {01D48116-37A2-4D33-B9EC-94793C702431} From e2aa797a925507425fd0fd686b2f73449c79bb77 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 5 Feb 2026 18:03:59 -0600 Subject: [PATCH 14/18] Remove Common.csproj. Use Microsoft.Data.SqlClient.TestCommon going forward. --- src/Microsoft.Data.SqlClient.sln | 15 ----- .../tests/Common/Common.csproj | 62 ------------------- 2 files changed, 77 deletions(-) delete mode 100644 src/Microsoft.Data.SqlClient/tests/Common/Common.csproj diff --git a/src/Microsoft.Data.SqlClient.sln b/src/Microsoft.Data.SqlClient.sln index e28112aa46..e55e77a36c 100644 --- a/src/Microsoft.Data.SqlClient.sln +++ b/src/Microsoft.Data.SqlClient.sln @@ -316,8 +316,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "steps", "steps", "{AD738BD4 EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Data.SqlClient.UnitTests", "Microsoft.Data.SqlClient\tests\UnitTests\Microsoft.Data.SqlClient.UnitTests.csproj", "{4461063D-2F2B-274C-7E6F-F235119D258E}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Common", "Microsoft.Data.SqlClient\tests\Common\Common.csproj", "{67128EC0-30F5-6A98-448B-55F88A1DE707}" -EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Stress", "Stress", "{02EA681E-C7D8-13C7-8484-4AC65E1B71E8}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "IMonitorLoader", "Microsoft.Data.SqlClient\tests\StressTests\IMonitorLoader\IMonitorLoader.csproj", "{1A29B520-D16A-35F2-5CAC-64573C86E63D}" @@ -633,18 +631,6 @@ Global {4461063D-2F2B-274C-7E6F-F235119D258E}.Release|x64.Build.0 = Release|x64 {4461063D-2F2B-274C-7E6F-F235119D258E}.Release|x86.ActiveCfg = Release|x86 {4461063D-2F2B-274C-7E6F-F235119D258E}.Release|x86.Build.0 = Release|x86 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Debug|Any CPU.Build.0 = Debug|Any CPU - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Debug|x64.ActiveCfg = Debug|x64 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Debug|x64.Build.0 = Debug|x64 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Debug|x86.ActiveCfg = Debug|x86 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Debug|x86.Build.0 = Debug|x86 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Release|Any CPU.ActiveCfg = Release|Any CPU - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Release|Any CPU.Build.0 = Release|Any CPU - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Release|x64.ActiveCfg = Release|x64 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Release|x64.Build.0 = Release|x64 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Release|x86.ActiveCfg = Release|x86 - {67128EC0-30F5-6A98-448B-55F88A1DE707}.Release|x86.Build.0 = Release|x86 {1A29B520-D16A-35F2-5CAC-64573C86E63D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {1A29B520-D16A-35F2-5CAC-64573C86E63D}.Debug|Any CPU.Build.0 = Debug|Any CPU {1A29B520-D16A-35F2-5CAC-64573C86E63D}.Debug|x64.ActiveCfg = Debug|Any CPU @@ -820,7 +806,6 @@ Global {09352F1D-878F-4F55-8AA2-6E47F1AD37D5} = {4CAE9195-4F1A-4D48-854C-1C9FBC512C66} {AD738BD4-6A02-4B88-8F93-FBBBA49A74C8} = {4CAE9195-4F1A-4D48-854C-1C9FBC512C66} {4461063D-2F2B-274C-7E6F-F235119D258E} = {0CC4817A-12F3-4357-912C-09315FAAD008} - {67128EC0-30F5-6A98-448B-55F88A1DE707} = {0CC4817A-12F3-4357-912C-09315FAAD008} {02EA681E-C7D8-13C7-8484-4AC65E1B71E8} = {0CC4817A-12F3-4357-912C-09315FAAD008} {1A29B520-D16A-35F2-5CAC-64573C86E63D} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8} {2AA12D54-540B-E515-CB82-80D691C9DCF1} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8} diff --git a/src/Microsoft.Data.SqlClient/tests/Common/Common.csproj b/src/Microsoft.Data.SqlClient/tests/Common/Common.csproj deleted file mode 100644 index efce75759f..0000000000 --- a/src/Microsoft.Data.SqlClient/tests/Common/Common.csproj +++ /dev/null @@ -1,62 +0,0 @@ - - - Common - netfx - netcoreapp - win - win-$(Platform) - $(ObjFolder)$(Configuration).$(Platform).$(AssemblyName) - $(BinFolder)$(Configuration).$(Platform).$(AssemblyName) - true - enable - - - - - $(DefineConstants),_UNIX - $(DefineConstants),_WINDOWS - - - - - - - runtime; build; native; contentfiles; analyzers; buildtransitive - all - - - - - - - - - runtime; build; native; contentfiles; analyzers; buildtransitive - all - - - runtime; build; native; contentfiles; analyzers; buildtransitive - all - - - - - PreserveNewest - xunit.runner.json - - - - - - - - - - - - - - - - - From 4d0b490a361bb0596a2b6437dd289f3b52272e3f Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Fri, 6 Feb 2026 13:08:13 -0600 Subject: [PATCH 15/18] Update buildguide --- BUILDGUIDE.md | 229 ++++++++++++++++---------------------------------- 1 file changed, 74 insertions(+), 155 deletions(-) diff --git a/BUILDGUIDE.md b/BUILDGUIDE.md index 5867ddcbfb..ccd9605d70 100644 --- a/BUILDGUIDE.md +++ b/BUILDGUIDE.md @@ -2,7 +2,9 @@ This document provides all the necessary details to build the driver and run tests present in the repository. -## .NET SDK +## Prerequisites + +### .NET SDK The projects in this repo require the .NET 10.0 SDK to build. Please ensure you have the latest version of that SDK installed. @@ -11,7 +13,7 @@ Tests and tools may require different .NET Runtimes that may be installed independently. For example, tests targeting .NET 8.0 will need that runtime installed. -## Visual Studio Pre-Requisites +### Visual Studio This project should be built with Visual Studio 2019+ for the best compatibility. The required set of components are provided in the below file: @@ -21,6 +23,40 @@ This project should be built with Visual Studio 2019+ for the best compatibility Once the environment is setup properly, execute the desired set of commands below from the _root_ folder to perform the respective operations: +### Maunal Test Prerequisites + +Manual Tests require the below setup to run: + +- SQL Server with enabled Shared Memory, TCP and Named Pipes Protocols and access to the Client OS. +- Databases "NORTHWIND" and "UdtTestDb" present in SQL Server, created using SQL scripts [createNorthwindDb.sql](tools/testsql/createNorthwindDb.sql) and [createUdtTestDb.sql](tools/testsql/createUdtTestDb.sql). To setup an Azure Database with "NORTHWIND" tables, use SQL Script: [createNorthwindAzureDb.sql](tools/testsql/createNorthwindAzureDb.sql). +- Make a copy of the configuration file [config.default.json](src/Microsoft.Data.SqlClient/tests/tools/Microsoft.Data.SqlClient.TestUtilities/config.default.json) and rename it to `config.json`. Update the values in `config.json`: + + |Property|Description|Value| + |------|--------|-------------------| + |TCPConnectionString | Connection String for a TCP enabled SQL Server instance. | `Server={servername};Database={Database_Name};Trusted_Connection=True;`
OR `Data Source={servername};Initial Catalog={Database_Name};Integrated Security=True;`| + |NPConnectionString | Connection String for a Named Pipes enabled SQL Server instance.| `Server=\\{servername}\pipe\sql\query;Database={Database_Name};Trusted_Connection=True;`
OR
`Data Source=np:{servername};Initial Catalog={Database_Name};Integrated Security=True;`| + |TCPConnectionStringHGSVBS | (Optional) Connection String for a TCP enabled SQL Server with Host Guardian Service (HGS) attestation protocol configuration. | `Server=tcp:{servername}; Database={Database_Name}; UID={UID}; PWD={PWD}; Attestation Protocol = HGS; Enclave Attestation Url = {AttestationURL};`| + |TCPConnectionStringNoneVBS | (Optional) Connection String for a TCP enabled SQL Server with a VBS Enclave and using None Attestation protocol configuration. | `Server=tcp:{servername}; Database={Database_Name}; UID={UID}; PWD={PWD}; Attestation Protocol = NONE;`| + |TCPConnectionStringAASSGX | (Optional) Connection String for a TCP enabled SQL Server with a SGX Enclave and using Microsoft Azure Attestation (AAS) attestation protocol configuration. | `Server=tcp:{servername}; Database={Database_Name}; UID={UID}; PWD={PWD}; Attestation Protocol = AAS; Enclave Attestation Url = {AttestationURL};`| + |EnclaveEnabled | Enables tests requiring an enclave-configured server.| + |TracingEnabled | Enables EventSource related tests | + |AADAuthorityURL | (Optional) Identifies the OAuth2 authority resource for `Server` specified in `AADPasswordConnectionString` | `https://login.windows.net/`, where `` is the tenant ID of the Azure Active Directory (Azure AD) tenant | + |AADPasswordConnectionString | (Optional) Connection String for testing Azure Active Directory Password Authentication. | `Data Source={server.database.windows.net}; Initial Catalog={Azure_DB_Name};Authentication=Active Directory Password; User ID={AAD_User}; Password={AAD_User_Password};`| + |AADSecurePrincipalId | (Optional) The Application Id of a registered application which has been granted permission to the database defined in the AADPasswordConnectionString. | {Application ID} | + |AADSecurePrincipalSecret | (Optional) A Secret defined for a registered application which has been granted permission to the database defined in the AADPasswordConnectionString. | {Secret} | + |AzureKeyVaultURL | (Optional) Azure Key Vault Identifier URL | `https://{keyvaultname}.vault.azure.net/` | + |AzureKeyVaultTenantId | (Optional) The Azure Active Directory tenant (directory) Id of the service principal. | _{Tenant ID of Active Directory}_ | + |SupportsIntegratedSecurity | (Optional) Whether or not the USER running tests has integrated security access to the target SQL Server.| `true` OR `false`| + |LocalDbAppName | (Optional) If Local Db Testing is supported, this property configures the name of Local DB App instance available in client environment. Empty string value disables Local Db testing. | Name of Local Db App to connect to.| + |LocalDbSharedInstanceName | (Optional) If LocalDB testing is supported and the instance is shared, this property configures the name of the shared instance of LocalDB to connect to. | Name of shared instance of LocalDB. | + |FileStreamDirectory | (Optional) If File Stream is enabled on SQL Server, pass local directory path to be used for setting up File Stream enabled database. | `D:\\escaped\\absolute\\path\\to\\directory\\` | + |UseManagedSNIOnWindows | (Optional) Enables testing with Managed SNI on Windows| `true` OR `false`| + |DNSCachingConnString | Connection string for a server that supports DNS Caching| + |EnclaveAzureDatabaseConnString | (Optional) Connection string for Azure database with enclaves | + |ManagedIdentitySupported | (Optional) When set to `false` **Managed Identity** related tests won't run. The default value is `true`. | + |IsManagedInstance | (Optional) When set to `true` **TVP** related tests will use on non-Azure bs files to compare test results. this is needed when testing against Managed Instances or TVP Tests will fail on Test set 3. The default value is `false`. | + |PowerShellPath | The full path to PowerShell.exe. This is not required if the path is present in the PATH environment variable. | `D:\\escaped\\absolute\\path\\to\\PowerShell.exe` | + ## MSBuild Reference ### Targets @@ -35,8 +71,6 @@ The following build targets are defined in `build.proj`: |`BuildNetCore`|Builds the .NET driver for all target frameworks.| |`BuildNetCoreAllOS`|Builds the .NET driver for all target frameworks and operating systems.| |`BuildNetFx`|Builds the .NET Framework driver for all target frameworks.| -|`BuildTestsNetCore`|Builds tests for the .NET driver.| -|`BuildTestsNetFx`|Builds tests for the .NET Framework driver.| |`Clean`|Cleans all generated files.| |`Restore`|Restores NuGet packages.| |`RunTests`|Runs the unit, functional, and manual tests for the .NET Framework and .NET drivers| @@ -55,149 +89,85 @@ build: |`Configuration`|`Debug`, `Release`|`Debug`|Sets the release configuration.| |`OSGroup`|`Unix`, `Windows_NT`, `AnyOS`|typically defaults to the client system's OS, unless using `BuildAllConfigurations` or an `AnyOS` specific target|The operating system to target.| |`Platform`|`AnyCPU`, `x86`, `x64`, `ARM`, `ARM64`|`AnyCPU`|May only be set when using package reference type or running tests.| -|`TestSet`|`1`, `2`, `3`, `AE`|all|Build or run a subset of the manual tests. Omit (default) to target all tests.| +|`TestSet`|`1`, `2`, `3`, `AE`, or any combination thereof|`''`|Build or run a subset of the manual tests. Omit (default) to run all tests.| |`DotnetPath`|Absolute file path to an installed `dotnet` version.|The system default specified by the path variable|Set to run tests using a specific dotnet version (e.g. C:\net6-win-x86\)| -|`TF`|`net8.0`, `net462`, `net47`, `net471`, `net472`, `net48`, `net481`|`net8.0` in netcore, `net462` in netfx|Sets the target framework when building or running tests. Not applicable when building the drivers.| +|`TF`|`net8.0`, `net462`, `net47`, `net471`, `net472`, `net48`, `net481`|`net9.0` in netcore, `net462` in netfx|Sets the target framework when building or running tests. Not applicable when building the drivers.| |`ResultsDirectory`|An absolute file path|./TestResults relative to current directory|Specifies where to write test results.| -## Example Workflows using MSBuild (Recommended) +## Example Commands to Run Tests Using MSBuild (Recommended) Using the default configuration and running all tests: ```bash -msbuild -t:BuildTestsNetFx -p:TF=net462 -msbuild -t:BuildTestsNetCore msbuild -t:RunTests ``` Using the Release configuration: ```bash -msbuild -t:BuildTestsNetFx -p:TF=net462 -p:Configuration=Release -msbuild -t:BuildTestsNetCore -p:Configuration=Release msbuild -t:RunTests -p:Configuration=Release ``` Running only the unit tests: ```bash -msbuild -t:BuildTestsNetFx -p:TF=net462 -msbuild -t:BuildTestsNetCore msbuild -t:RunUnitTests ``` Using a specific .NET runtime to run tests: ```bash -msbuild -t:BuildTestsNetFx -p:TF=net462 -msbuild -t:BuildTestsNetCore msbuild -t:RunTests -p:DotnetPath=C:\net8-win-x86\ ``` -### Running Manual Tests - -#### Pre-Requisites for running Manual tests - -Manual Tests require the below setup to run: - -- SQL Server with enabled Shared Memory, TCP and Named Pipes Protocols and access to the Client OS. -- Databases "NORTHWIND" and "UdtTestDb" present in SQL Server, created using SQL scripts [createNorthwindDb.sql](tools/testsql/createNorthwindDb.sql) and [createUdtTestDb.sql](tools/testsql/createUdtTestDb.sql). To setup an Azure Database with "NORTHWIND" tables, use SQL Script: [createNorthwindAzureDb.sql](tools/testsql/createNorthwindAzureDb.sql). -- Make a copy of the configuration file [config.default.json](src/Microsoft.Data.SqlClient/tests/tools/Microsoft.Data.SqlClient.TestUtilities/config.default.json) and rename it to `config.json`. Update the values in `config.json`: - - |Property|Description|Value| - |------|--------|-------------------| - |TCPConnectionString | Connection String for a TCP enabled SQL Server instance. | `Server={servername};Database={Database_Name};Trusted_Connection=True;`
OR `Data Source={servername};Initial Catalog={Database_Name};Integrated Security=True;`| - |NPConnectionString | Connection String for a Named Pipes enabled SQL Server instance.| `Server=\\{servername}\pipe\sql\query;Database={Database_Name};Trusted_Connection=True;`
OR
`Data Source=np:{servername};Initial Catalog={Database_Name};Integrated Security=True;`| - |TCPConnectionStringHGSVBS | (Optional) Connection String for a TCP enabled SQL Server with Host Guardian Service (HGS) attestation protocol configuration. | `Server=tcp:{servername}; Database={Database_Name}; UID={UID}; PWD={PWD}; Attestation Protocol = HGS; Enclave Attestation Url = {AttestationURL};`| - |TCPConnectionStringNoneVBS | (Optional) Connection String for a TCP enabled SQL Server with a VBS Enclave and using None Attestation protocol configuration. | `Server=tcp:{servername}; Database={Database_Name}; UID={UID}; PWD={PWD}; Attestation Protocol = NONE;`| - |TCPConnectionStringAASSGX | (Optional) Connection String for a TCP enabled SQL Server with a SGX Enclave and using Microsoft Azure Attestation (AAS) attestation protocol configuration. | `Server=tcp:{servername}; Database={Database_Name}; UID={UID}; PWD={PWD}; Attestation Protocol = AAS; Enclave Attestation Url = {AttestationURL};`| - |EnclaveEnabled | Enables tests requiring an enclave-configured server.| - |TracingEnabled | Enables EventSource related tests | - |AADAuthorityURL | (Optional) Identifies the OAuth2 authority resource for `Server` specified in `AADPasswordConnectionString` | `https://login.windows.net/`, where `` is the tenant ID of the Azure Active Directory (Azure AD) tenant | - |AADPasswordConnectionString | (Optional) Connection String for testing Azure Active Directory Password Authentication. | `Data Source={server.database.windows.net}; Initial Catalog={Azure_DB_Name};Authentication=Active Directory Password; User ID={AAD_User}; Password={AAD_User_Password};`| - |AADSecurePrincipalId | (Optional) The Application Id of a registered application which has been granted permission to the database defined in the AADPasswordConnectionString. | {Application ID} | - |AADSecurePrincipalSecret | (Optional) A Secret defined for a registered application which has been granted permission to the database defined in the AADPasswordConnectionString. | {Secret} | - |AzureKeyVaultURL | (Optional) Azure Key Vault Identifier URL | `https://{keyvaultname}.vault.azure.net/` | - |AzureKeyVaultTenantId | (Optional) The Azure Active Directory tenant (directory) Id of the service principal. | _{Tenant ID of Active Directory}_ | - |SupportsIntegratedSecurity | (Optional) Whether or not the USER running tests has integrated security access to the target SQL Server.| `true` OR `false`| - |LocalDbAppName | (Optional) If Local Db Testing is supported, this property configures the name of Local DB App instance available in client environment. Empty string value disables Local Db testing. | Name of Local Db App to connect to.| - |LocalDbSharedInstanceName | (Optional) If LocalDB testing is supported and the instance is shared, this property configures the name of the shared instance of LocalDB to connect to. | Name of shared instance of LocalDB. | - |FileStreamDirectory | (Optional) If File Stream is enabled on SQL Server, pass local directory path to be used for setting up File Stream enabled database. | `D:\\escaped\\absolute\\path\\to\\directory\\` | - |UseManagedSNIOnWindows | (Optional) Enables testing with Managed SNI on Windows| `true` OR `false`| - |DNSCachingConnString | Connection string for a server that supports DNS Caching| - |EnclaveAzureDatabaseConnString | (Optional) Connection string for Azure database with enclaves | - |ManagedIdentitySupported | (Optional) When set to `false` **Managed Identity** related tests won't run. The default value is `true`. | - |IsManagedInstance | (Optional) When set to `true` **TVP** related tests will use on non-Azure bs files to compare test results. this is needed when testing against Managed Instances or TVP Tests will fail on Test set 3. The default value is `false`. | - |PowerShellPath | The full path to PowerShell.exe. This is not required if the path is present in the PATH environment variable. | `D:\\escaped\\absolute\\path\\to\\PowerShell.exe` | - -## Example workflows using the Dotnet SDK - -### Run Functional Tests - -- Windows (`netfx x86`): - -```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\FunctionalTests\Microsoft.Data.SqlClient.Tests.csproj" -p:Platform="x86" -p:Configuration="Release" -p:TestTargetOS="Windowsnetfx" --no-build -v n --filter "category!=nonnetfxtests&category!=failing&category!=nonwindowstests" -``` - -- Windows (`netfx x64`): +To run tests against a specific version of .NET/.NET Framework, set the `-p:TF` parameter. ```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\FunctionalTests\Microsoft.Data.SqlClient.Tests.csproj" -p:Platform="x64" -p:Configuration="Release" -p:TestTargetOS="Windowsnetfx" --no-build -v n --filter "category!=nonnetfxtests&category!=failing&category!=nonwindowstests" +msbuild -t:RunTests -p:TF=net8.0 +msbuild -t:RunTests -p:TF=net462 ``` -- AnyCPU: +## Example Commands to Run Tests using `dotnet` - Project reference only builds Driver with `AnyCPU` platform, and underlying process decides to run the tests with a compatible architecture (x64, x86, ARM64). +Under the hood, the MSBuild commands to run tests use `dotnet` commands. But, if you wish to run +them without the overhead of wrapping/unwrapping in MSBuild, you can run them directly. - Windows (`netcoreapp`): +To change the processor architecture that runs the test (where possible, ie, x86 on x64), use the +appropriate `dotnet` executable. -```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\FunctionalTests\Microsoft.Data.SqlClient.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Windowsnetcoreapp" --no-build -v n --filter "category!=nonnetcoreapptests&category!=failing&category!=nonwindowstests" -``` - - Unix (`netcoreapp`): - -```bash -dotnet test "src/Microsoft.Data.SqlClient/tests/FunctionalTests/Microsoft.Data.SqlClient.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Unixnetcoreapp" --no-build -v n --filter "category!=nonnetcoreapptests&category!=failing&category!=nonlinuxtests&category!=nonuaptests" -``` - -### Run Manual Tests +By default, the tests will be executed on all supported .NET/.NET framework versions. To run on a +specific version, pass the `-f` parameter with the desired version (eg `net9.0`). -- Windows (`netfx x86`): +The `--filter` parameter is used to select which tests run. The default `category!=failing& +category!=flaky` prevents tests that are known to be failing or flaky from running. To run a +specific test, use `FullyQualifiedName=[fully qualified name of the test method]` as the filter +parameter. To run all possible tests, even known failing and flaky ones, simply omit the filter +parameter. Please note, however, that this will still omit tests that cannot run on the current +platform or with the current test configuration (eg, Windows tests on Linux, or SQL DB tests when +Azure Synapse is configured). -```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="x86" -p:Configuration="Release" -p:TestTargetOS="Windowsnetfx" --no-build -v n --filter "category!=nonnetfxtests&category!=failing&category!=nonwindowstests" - ``` - -- Windows (`netfx x64`): +### Run Functional Tests ```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="x64" -p:Configuration="Release" -p:TestTargetOS="Windowsnetfx" --no-build -v n --filter "category!=nonnetfxtests&category!=failing&category!=nonwindowstests" -``` +dotnet test "src/Microsoft.Data.SqlClient/tests/FunctionalTests/ Microsoft.Data.SqlClient.FunctionalTests.csproj" \ + -p:Configuration=Release \ + --filter "category!=failing&category!=flaky" -- Windows (`netfx`): - -```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Windowsnetfx" --no-build -v n --filter "category!=nonnetfxtests&category!=failing&category!=nonwindowstests" ``` -- Windows (`netcoreapp`): - -```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Windowsnetcoreapp" --no-build -v n --filter "category!=nonnetcoreapptests&category!=failing&category!=nonwindowstests" -``` - -- Unix (`netcoreapp`): +### Run Manual Tests ```bash -dotnet test "src/Microsoft.Data.SqlClient/tests/ManualTests/Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Unixnetcoreapp" --no-build -v n --filter "category!=nonnetcoreapptests&category!=failing&category!=nonlinuxtests&category!=nonuaptests" +dotnet test "src/Microsoft.Data.SqlClient/tests/ManualTests/Microsoft.Data.SqlClient.ManualTests.csproj" \ + -p:Configuration=Release \ + --filter "category!=failing&category!=flaky" ``` -## Run A Single Test - +### Run Unit Tests ```bash -dotnet test "src\Microsoft.Data.SqlClient\tests\ManualTests\Microsoft.Data.SqlClient.ManualTesting.Tests.csproj" -p:Platform="AnyCPU" -p:Configuration="Release" -p:TestTargetOS="Windowsnetcoreapp" --no-build -v n --filter "FullyQualifiedName=Microsoft.Data.SqlClient.ManualTesting.Tests.AlwaysEncrypted.CspProviderExt.TestKeysFromCertificatesCreatedWithMultipleCryptoProviders" +dotnet test "src/Microsoft.Data.SqlClient/tests/UnitTests/Microsoft.Data.SqlClient.UnitTests.csproj" \ + -p:Configuration=Release \ + --filter "category!=failing&category!=flaky" ``` ## Testing with Package References @@ -238,40 +208,15 @@ dotnet build -t:BuildAll -p:ReferenceType=Package dotnet build -t:BuildAKVNetCore -p:ReferenceType=Package dotnet build -t:GenerateMdsPackage dotnet build -t:GenerateAkvPackage -dotnet build -t:BuildTestsNetCore -p:ReferenceType=Package ``` The above will build the MDS and AKV components, place their NuGet packages into -the `packages/` directory, and then build the tests using those packages. +the `packages/` directory. A non-AnyCPU platform reference can only be used with package reference type. Otherwise, the specified platform will be replaced with AnyCPU in the build process. -### Building Tests with ReferenceType - -For .NET: - -```bash -# Project is the default reference type. The below commands are equivalent: -msbuild -t:BuildTestsNetCore -msbuild -t:BuildTestsNetCore -p:ReferenceType=Project - -# Package reference type: -msbuild -t:BuildTestsNetCore -p:ReferenceType=Package -``` - -For .NET Framework: - -```bash -# Project is the default reference type. The below commands are equivalent: -msbuild -t:BuildTestsNetFx -p:TF=net462 -msbuild -t:BuildTestsNetFx -p:TF=net462 -p:ReferenceType=Project - -# Package reference type: -msbuild -t:BuildTestsNetFx -p:TF=net462 -p:ReferenceType=Package -``` - ### Running Tests with Reference Type Provide property to `dotnet test` commands for testing desired reference type. @@ -280,31 +225,6 @@ Provide property to `dotnet test` commands for testing desired reference type. dotnet test -p:ReferenceType=Project ... ``` -## Testing with Custom TargetFramework (traditional) - -Tests can be built and run with custom Target Frameworks. See the below examples. - -### Building Tests with custom target framework - -```bash -# Build the tests for custom .NET Framework target -msbuild -t:BuildTestsNetFx -p:TF=net462 -``` - -```bash -# Build the tests for custom .NET target -msbuild -t:BuildTestsNetCore -p:TF=net8.0 -``` - -### Running Tests with custom target framework (traditional) - -```bash -# Run tests with custom .NET Framework target -dotnet test -p:TargetNetFxVersion=net462 ... - -# Run tests with custom .NET target -dotnet test -p:TargetNetCoreVersion=net8.0 ... -``` ## Using Managed SNI on Windows @@ -335,19 +255,18 @@ When connecting to a server, if a protocol lower than TLS 1.2 is negotiated, a s ### Using VSTest ```bash -dotnet test --collect:"Code Coverage" +dotnet test [test_properties...] --collect:"Code Coverage" ``` ### Using Coverlet Collector ```bash -dotnet test --collect:"XPlat Code Coverage" +dotnet test [test_properties...] --collect:"XPlat Code Coverage" ``` ## Run Performance Tests -The performance tests live here: -`src\Microsoft.Data.SqlClient\tests\PerformanceTests\` +The performance tests live here: `src\Microsoft.Data.SqlClient\tests\PerformanceTests\` They can be run from the command line by following the instructions below. From fcafada1131b28e79475d553d0af07a2a2a877fe Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Fri, 6 Feb 2026 13:31:54 -0600 Subject: [PATCH 16/18] Typos --- BUILDGUIDE.md | 6 +++--- ...a.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/BUILDGUIDE.md b/BUILDGUIDE.md index ccd9605d70..5dea857f26 100644 --- a/BUILDGUIDE.md +++ b/BUILDGUIDE.md @@ -23,7 +23,7 @@ This project should be built with Visual Studio 2019+ for the best compatibility Once the environment is setup properly, execute the desired set of commands below from the _root_ folder to perform the respective operations: -### Maunal Test Prerequisites +### Manual Test Prerequisites Manual Tests require the below setup to run: @@ -54,7 +54,7 @@ Manual Tests require the below setup to run: |DNSCachingConnString | Connection string for a server that supports DNS Caching| |EnclaveAzureDatabaseConnString | (Optional) Connection string for Azure database with enclaves | |ManagedIdentitySupported | (Optional) When set to `false` **Managed Identity** related tests won't run. The default value is `true`. | - |IsManagedInstance | (Optional) When set to `true` **TVP** related tests will use on non-Azure bs files to compare test results. this is needed when testing against Managed Instances or TVP Tests will fail on Test set 3. The default value is `false`. | + |IsManagedInstance | (Optional) When set to `true` **TVP** related tests will use non-Azure bsl files to compare test results. This is needed when testing against Azure Managed Instances; otherwise TVP Tests will fail on TestSet 3. The default value is `false`. | |PowerShellPath | The full path to PowerShell.exe. This is not required if the path is present in the PATH environment variable. | `D:\\escaped\\absolute\\path\\to\\PowerShell.exe` | ## MSBuild Reference @@ -149,7 +149,7 @@ Azure Synapse is configured). ### Run Functional Tests ```bash -dotnet test "src/Microsoft.Data.SqlClient/tests/FunctionalTests/ Microsoft.Data.SqlClient.FunctionalTests.csproj" \ +dotnet test "src/Microsoft.Data.SqlClient/tests/FunctionalTests/Microsoft.Data.SqlClient.FunctionalTests.csproj" \ -p:Configuration=Release \ --filter "category!=failing&category!=flaky" diff --git a/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj b/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj index f173c4ea01..8b1aa8539b 100644 --- a/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj +++ b/src/Microsoft.Data.SqlClient/add-ons/AzureKeyVaultProvider/Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider.csproj @@ -8,7 +8,7 @@ - + $(BinFolder)$(Configuration).$(Platform)\AzureKeyVaultProvider $(ObjFolder)$(Configuration).$(Platform)\AzureKeyVaultProvider $(BinFolder)$(Configuration).$(Platform)\$(AssemblyName).xml From 618991cd60c1c2dc5bbe517fd2d90024ea745147 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 12 Feb 2026 12:44:16 -0600 Subject: [PATCH 17/18] Make nuget.config.local the nuget.config --- NuGet.config | 11 ++++++++--- NuGet.config.local | 25 ------------------------- build.proj | 6 +----- 3 files changed, 9 insertions(+), 33 deletions(-) delete mode 100644 NuGet.config.local diff --git a/NuGet.config b/NuGet.config index 89a5578c7d..a16ff70302 100644 --- a/NuGet.config +++ b/NuGet.config @@ -1,18 +1,23 @@  - + + diff --git a/NuGet.config.local b/NuGet.config.local deleted file mode 100644 index 919c0dc628..0000000000 --- a/NuGet.config.local +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/build.proj b/build.proj index c57fab0306..09653709a2 100644 --- a/build.proj +++ b/build.proj @@ -10,10 +10,6 @@ false - - $(RepoRoot)/NuGet.config - $(NuGetConfigFile).local - Debug AnyCPU @@ -32,7 +28,7 @@ $(TF) true - Configuration=$(Configuration);ReferenceType=$(ReferenceType);RestoreConfigFile=$(NuGetConfigFile) + Configuration=$(Configuration);ReferenceType=$(ReferenceType); $(CommonProperties);AssemblyVersion=$(SqlServerAssemblyVersion);AssemblyFileVersion=$(SqlServerAssemblyFileVersion);Version=$(SqlServerPackageVersion); $(CommonProperties);AssemblyFileVersion=$(AssemblyFileVersion);TargetsWindows=$(TargetsWindows);TargetsUnix=$(TargetsUnix); $(ProjectProperties);BuildForRelease=false;TargetNetCoreVersion=$(TargetNetCoreVersion);TargetNetFxVersion=$(TargetNetFxVersion) From 2a67d117391935f1d1dbb74ab5204a3f350e4544 Mon Sep 17 00:00:00 2001 From: Ben Russell Date: Thu, 12 Feb 2026 13:28:24 -0600 Subject: [PATCH 18/18] Remove nuget.config switches from pipelines --- eng/pipelines/jobs/pack-azure-package-ci-job.yml | 9 +-------- eng/pipelines/jobs/test-azure-package-ci-job.yml | 9 +-------- eng/pipelines/stages/stress-tests-ci-stage.yml | 6 +++--- 3 files changed, 5 insertions(+), 19 deletions(-) diff --git a/eng/pipelines/jobs/pack-azure-package-ci-job.yml b/eng/pipelines/jobs/pack-azure-package-ci-job.yml index 33169bbe03..41e3317732 100644 --- a/eng/pipelines/jobs/pack-azure-package-ci-job.yml +++ b/eng/pipelines/jobs/pack-azure-package-ci-job.yml @@ -95,13 +95,6 @@ jobs: - name: dotnetPackagesDir value: $(Build.StagingDirectory)/dotnetPackages - # The NuGet.config file to use for restoring packages. - - name: nugetConfigFile - ${{ if eq(parameters.referenceType, 'Package') }}: - value: $(Build.SourcesDirectory)/NuGet.config.local - ${{ else }}: - value: $(Build.SourcesDirectory)/NuGet.config - # dotnet CLI arguments common to all commands. - name: commonArguments value: >- @@ -168,7 +161,7 @@ jobs: command: custom custom: restore projects: $(project) - arguments: $(commonArguments) --configfile $(nugetConfigFile) + arguments: $(commonArguments) # Build the project. - task: DotNetCoreCLI@2 diff --git a/eng/pipelines/jobs/test-azure-package-ci-job.yml b/eng/pipelines/jobs/test-azure-package-ci-job.yml index 2d2da14435..15bcad98bd 100644 --- a/eng/pipelines/jobs/test-azure-package-ci-job.yml +++ b/eng/pipelines/jobs/test-azure-package-ci-job.yml @@ -136,13 +136,6 @@ jobs: - name: project value: src/Microsoft.Data.SqlClient.Extensions/Azure/test/Azure.Test.csproj - # The NuGet.config file to use for restoring packages. - - name: nugetConfigFile - ${{ if eq(parameters.referenceType, 'Package') }}: - value: $(Build.SourcesDirectory)/NuGet.config.local - ${{ else }}: - value: $(Build.SourcesDirectory)/NuGet.config - # dotnet CLI arguments common to all commands. - name: commonArguments value: >- @@ -260,7 +253,7 @@ jobs: command: custom custom: restore projects: $(project) - arguments: $(commonArguments) --configfile $(nugetConfigFile) + arguments: $(commonArguments) # Build the project. - task: DotNetCoreCLI@2 diff --git a/eng/pipelines/stages/stress-tests-ci-stage.yml b/eng/pipelines/stages/stress-tests-ci-stage.yml index d1eae30ff4..22905f23de 100644 --- a/eng/pipelines/stages/stress-tests-ci-stage.yml +++ b/eng/pipelines/stages/stress-tests-ci-stage.yml @@ -140,7 +140,7 @@ stages: mdsArtifactsName: ${{ parameters.mdsArtifactsName }} solution: $(solution) testProject: $(testProject) - restoreArguments: $(commonArguments) --configfile=$(Build.SourcesDirectory)/NuGet.config.local + restoreArguments: $(commonArguments) buildArguments: $(buildArguments) netTestRuntimes: ${{ parameters.netTestRuntimes }} configContent: $(ConfigContent) @@ -160,7 +160,7 @@ stages: mdsArtifactsName: ${{ parameters.mdsArtifactsName }} solution: $(solution) testProject: $(testProject) - restoreArguments: $(commonArguments) --configfile=$(Build.SourcesDirectory)/NuGet.config.local + restoreArguments: $(commonArguments) buildArguments: $(buildArguments) netTestRuntimes: ${{ parameters.netTestRuntimes }} # Note that we include the .NET Framework runtimes for test runs on @@ -183,7 +183,7 @@ stages: mdsArtifactsName: ${{ parameters.mdsArtifactsName }} solution: $(solution) testProject: $(testProject) - restoreArguments: $(commonArguments) --configfile=$(Build.SourcesDirectory)/NuGet.config.local + restoreArguments: $(commonArguments) buildArguments: $(buildArguments) netTestRuntimes: ${{ parameters.netTestRuntimes }} configContent: $(ConfigContent)