From 1bc77eaef88adceaa91749f0e7a98f002344828c Mon Sep 17 00:00:00 2001 From: Bill Schnurr Date: Tue, 2 Dec 2025 19:31:18 -0800 Subject: [PATCH 01/75] Add dynamic runtimesettings (#8341) * Fix TestExplorer by selecting the grouping button in this form 'Project,Namespace,Class' then pass in the project name to the tests so that we follow down the test tree correctly * remove comment * format doc * add a new azure stage template for ptvs ui tests * Try fixing integration testing. convert azure test stage to yml in uitest-integration-stage.yml --- .../test/uitest-integration-stage.yml | 149 +++++++++++++++++ Python/Tests/Core.UI/TestExplorerTests.cs | 2 +- .../TestExplorerTests.cs | 2 + .../Utilities.Python/PythonTestExplorer.cs | 155 +++++++++++------- azure-pipelines-integration-tests.yml | 2 +- 5 files changed, 250 insertions(+), 60 deletions(-) create mode 100644 Build/azuredevops/test/uitest-integration-stage.yml diff --git a/Build/azuredevops/test/uitest-integration-stage.yml b/Build/azuredevops/test/uitest-integration-stage.yml new file mode 100644 index 0000000000..b248a2f879 --- /dev/null +++ b/Build/azuredevops/test/uitest-integration-stage.yml @@ -0,0 +1,149 @@ +parameters: + - name: BinariesDirectory + type: string + default: '$(Drop)/binaries' + - name: CleanupProcesses + type: string + default: 'devenv, vshub, microsoft.vshub.server.httphost, python, ipy, microsoft.pythontools.analyzer, vstest.executionengine.x86, vstest.discoveryengine.x86' + - name: Drop + type: string + default: '$(System.ArtifactsDirectory)/$(DefinitionName)' + - name: TestFilterCriteria + type: string + default: 'Priority=0' + - name: UITestNames + type: string + default: '' + +steps: + - task: ExtractFiles@1 + displayName: Extract files + condition: succeeded() + inputs: + archiveFilePatterns: '${{ parameters.Drop }}/TestData/TestData.zip' + destinationFolder: '${{ parameters.Drop }}/TestData' + cleanDestinationFolder: false + overwriteExistingFiles: false + + - task: PowerShell@2 + displayName: Cleanup + condition: succeeded() + continueOnError: true + timeoutInMinutes: 5 + inputs: + targetType: inline + arguments: '${{ parameters.CleanupProcesses }}' + script: | + param ([string[]]$names) + $running = Get-Process -Name $names -ErrorAction SilentlyContinue + while ($running) { + Write-Host 'Killing:' + $running + try { + $running | Stop-Process -Force + } catch { + } + Start-Sleep -Seconds 3 + $running = Get-Process -Name $names -ErrorAction SilentlyContinue + } + errorActionPreference: stop + failOnStderr: true + + - task: CopyFiles@2 + displayName: Copy TestData into binaries + condition: succeeded() + continueOnError: true + inputs: + SourceFolder: '${{ parameters.Drop }}/TestData' + Contents: '**' + TargetFolder: '${{ parameters.BinariesDirectory }}/TestData' + CleanTargetFolder: 'true' + OverWrite: 'false' + flattenFolders: 'false' + preserveTimestamp: 'false' + retryCount: '0' + + - task: CopyFiles@2 + displayName: Copy runsettings to binary folder + condition: succeeded() + inputs: + SourceFolder: '${{ parameters.BinariesDirectory }}/TestData' + Contents: 'default.runsettings' + TargetFolder: '${{ parameters.BinariesDirectory }}' + CleanTargetFolder: 'false' + OverWrite: 'false' + flattenFolders: 'false' + preserveTimestamp: 'false' + retryCount: '0' + + - task: PowerShell@2 + displayName: Skip Verification + condition: succeeded() + inputs: + targetType: inline + script: | + reg import "${{ parameters.BinariesDirectory }}\TestData\EnableSkipVerification.reg" + errorActionPreference: stop + failOnStderr: false + + - task: VSTest@2 + displayName: '[MultiConfiguration] Run UI Test ${{ parameters.UITestNames }}' + condition: succeeded() + continueOnError: true + inputs: + testSelector: testAssemblies + testAssemblyVer2: '${{ parameters.UITestNames }}UITestsRunner.dll' + tcmTestRun: '$(test.RunId)' + searchFolder: '${{ parameters.BinariesDirectory }}' + resultsFolder: '$(Agent.TempDirectory)/TestResults' + testFiltercriteria: '${{ parameters.TestFilterCriteria }}' + runOnlyImpactedTests: false + runAllTestsAfterXBuilds: 50 + uiTests: true + vstestLocationMethod: version + vsTestVersion: latest + runSettingsFile: '${{ parameters.BinariesDirectory }}/default.runsettings' + overrideTestrunParameters: '-TargetFrameworkVersion .NETFramework,Version=v4.7.2' + runInParallel: false + runTestsInIsolation: false + codeCoverageEnabled: true + distributionBatchType: basedOnExecutionTime + batchingBasedOnAgentsOption: autoBatchSize + customBatchSizeValue: 10 + batchingBasedOnExecutionTimeOption: customTimeBatchSize + customRunTimePerBatchValue: 300 + dontDistribute: false + testRunTitle: '${{ parameters.UITestNames }} UI Tests' + publishRunAttachments: true + failOnMinTestsNotRun: false + minimumExpectedTests: 1 + diagnosticsEnabled: true + collectDumpOn: onAbortOnly + rerunFailedTests: true + rerunType: basedOnTestFailurePercentage + rerunFailedThreshold: 50 + rerunFailedTestCasesMaxLimit: 5 + rerunMaxAttempts: 2 + + - task: PowerShell@2 + displayName: Cleanup + condition: succeeded() + timeoutInMinutes: 5 + inputs: + targetType: inline + arguments: '${{ parameters.CleanupProcesses }}' + script: | + param ([string[]]$names) + $running = Get-Process -Name $names -ErrorAction SilentlyContinue + while ($running) { + Write-Host 'Killing:' + $running + try { + $running | Stop-Process -Force + } catch { + } + Start-Sleep -Seconds 3 + $running = Get-Process -Name $names -ErrorAction SilentlyContinue + } + errorActionPreference: stop + failOnStderr: true diff --git a/Python/Tests/Core.UI/TestExplorerTests.cs b/Python/Tests/Core.UI/TestExplorerTests.cs index a22c074950..4555d42885 100644 --- a/Python/Tests/Core.UI/TestExplorerTests.cs +++ b/Python/Tests/Core.UI/TestExplorerTests.cs @@ -65,7 +65,7 @@ public void RunAllUnittestProject(PythonVisualStudioApp app) { var sln = app.CopyProjectForTest(@"TestData\TestExplorerUnittest.sln"); app.OpenProject(sln); - RunAllTests(app, AllUnittests); + RunAllTests(app, AllUnittests, Path.GetFileNameWithoutExtension(sln)); } public void RunAllUnittestWorkspace(PythonVisualStudioApp app) { diff --git a/Python/Tests/PythonToolsUITestsRunner/TestExplorerTests.cs b/Python/Tests/PythonToolsUITestsRunner/TestExplorerTests.cs index de5292aeee..565c573553 100644 --- a/Python/Tests/PythonToolsUITestsRunner/TestExplorerTests.cs +++ b/Python/Tests/PythonToolsUITestsRunner/TestExplorerTests.cs @@ -75,12 +75,14 @@ public void DebugPytestWorkspace() { _vs.RunTest(nameof(PythonToolsUITests.TestExplorerTests.DebugPytestWorkspace)); } + [Ignore] [TestMethod, Priority(UITestPriority.P0)] [TestCategory("Installed")] public void DebugUnittestProject() { _vs.RunTest(nameof(PythonToolsUITests.TestExplorerTests.DebugUnittestProject)); } + [Ignore] [TestMethod, Priority(UITestPriority.P0)] [TestCategory("Installed")] public void DebugUnittestWorkspace() { diff --git a/Python/Tests/Utilities.Python/PythonTestExplorer.cs b/Python/Tests/Utilities.Python/PythonTestExplorer.cs index b55e810a8c..e48c40c3fe 100644 --- a/Python/Tests/Utilities.Python/PythonTestExplorer.cs +++ b/Python/Tests/Utilities.Python/PythonTestExplorer.cs @@ -14,18 +14,21 @@ // See the Apache Version 2.0 License for specific language governing // permissions and limitations under the License. +using Microsoft.VisualStudio.TestTools.UnitTesting; using System; using System.Threading; using System.Windows.Automation; -using Microsoft.VisualStudio.TestTools.UnitTesting; -namespace TestUtilities.UI { - public class PythonTestExplorer : AutomationWrapper { +namespace TestUtilities.UI +{ + public class PythonTestExplorer : AutomationWrapper + { private readonly VisualStudioApp _app; private readonly AutomationWrapper _searchBar; private PythonTestExplorerGridView _tests; - private static class TestCommands { + private static class TestCommands + { public const string GroupBy = "TestExplorer.GroupBy"; public const string RunAllTests = "TestExplorer.RunAllTests"; public const string CopyDetails = "TestExplorer.CopyDetails"; @@ -33,14 +36,18 @@ private static class TestCommands { } public PythonTestExplorer(VisualStudioApp app, AutomationElement element, AutomationWrapper searchBarTextBox) - : base(element) { + : base(element) + { _app = app; _searchBar = searchBarTextBox ?? throw new ArgumentNullException(nameof(searchBarTextBox)); } - public PythonTestExplorerGridView Tests { - get { - if (_tests == null) { + public PythonTestExplorerGridView Tests + { + get + { + if (_tests == null) + { var el = this.Element.FindFirst( TreeScope.Descendants, new AndCondition( @@ -54,7 +61,8 @@ public PythonTestExplorerGridView Tests { ) ) ); - if (el != null) { + if (el != null) + { _tests = new PythonTestExplorerGridView(el); } } @@ -62,13 +70,15 @@ public PythonTestExplorerGridView Tests { } } - public string GetTestDetailSummary() { + public string GetTestDetailSummary() + { // Root is the Test Explorer tool window element you already have. var summaryControl = Element.FindFirst( TreeScope.Descendants, new PropertyCondition(AutomationElement.ClassNameProperty, "SummaryControl") ); - if (summaryControl == null) { + if (summaryControl == null) + { return string.Empty; } @@ -77,17 +87,20 @@ public string GetTestDetailSummary() { TreeScope.Descendants, new PropertyCondition(AutomationElement.ClassNameProperty, "WpfTextView") ); - if (textView == null) { + if (textView == null) + { return string.Empty; } // Try TextPattern. object p; - if (textView.TryGetCurrentPattern(TextPattern.Pattern, out p)) { + if (textView.TryGetCurrentPattern(TextPattern.Pattern, out p)) + { return ((TextPattern)p).DocumentRange.GetText(int.MaxValue); } // Fallback ValuePattern. - if (textView.TryGetCurrentPattern(ValuePattern.Pattern, out p)) { + if (textView.TryGetCurrentPattern(ValuePattern.Pattern, out p)) + { return ((ValuePattern)p).Current.Value; } @@ -95,16 +108,19 @@ public string GetTestDetailSummary() { return textView.Current.Name ?? string.Empty; } - public string GetDetailsWithRetry() { + public string GetDetailsWithRetry() + { string details = string.Empty; - for (int i = 0; i < 5; i++) { + for (int i = 0; i < 5; i++) + { var detailsTextBox = this.FindByName("Test Detail Summary"); AutomationWrapper.CheckNullElement(detailsTextBox, "Missing: Test Detail Summary"); // Copy to clipboard details = GetTestDetailSummary(); - if (details.Contains("Source:")) { + if (details.Contains("Source:")) + { return details; } @@ -117,65 +133,85 @@ public string GetDetailsWithRetry() { /// /// Set the grouping to namespace. /// - public void GroupByProjectNamespaceClass() { - // TODO: figure out how to programmatically change this - // it's now a popup window that appears on TestExplorer.GroupBy command - // well, at least when you click on it with the mouse - // It's not coming up when invoking the command programmatically - - //var groupCommand = _app.Dte.Commands.Item(TestCommands.GroupBy); - //Assert.IsNotNull(groupCommand, "GroupBy command not found"); - - - //if (!groupCommand.IsAvailable) { - // // Group command is not available when show hierarchy is on - // //_app.ExecuteCommand(TestCommands.ToggleShowTestHierarchy); - // _app.WaitForCommandAvailable(groupCommand, TimeSpan.FromSeconds(5)); - //} - - //_app.ExecuteCommand(TestCommands.GroupBy); // by class - - //Thread.Sleep(100); + public void GroupByProjectNamespaceClass() + { + // Try execute the GroupBy command to display grouping popup. + try + { + _app.Dte.ExecuteCommand(TestCommands.GroupBy); + } + catch + { + // Swallow if command not available; we'll still try to locate the option. + } - //var element = _app.Element.FindFirst(TreeScope.Descendants, new AndCondition( - // new PropertyCondition( - // AutomationElement.NameProperty, - // "Project, Namespace, Class" - // ), - // new PropertyCondition( - // AutomationElement.ClassNameProperty, - // "TextBlock" - // ) - //)); - //Assert.IsNotNull(element); + // Allow UI to render the popup + Thread.Sleep(200); + + // Attempt to find the "Project, Namespace, Class" option and invoke it. + AutomationElement element = null; + for (int i = 0; i < 5 && element == null; i++) + { + element = _app.Element.FindFirst( + TreeScope.Descendants, + new AndCondition( + new PropertyCondition(AutomationElement.NameProperty, "Project, Namespace, Class"), + new PropertyCondition(AutomationElement.ClassNameProperty, "TextBlock") + ) + ); + if (element == null) + { + Thread.Sleep(200); + } + } - //var menuItem = element.CachedParent; - //Assert.IsNotNull(menuItem); + if (element != null) + { + // Use TreeWalker to get parent; CachedParent may be null depending on cache policy + var menuItem = element.CachedParent; + if (menuItem == null) + { + var walker = TreeWalker.RawViewWalker; + menuItem = walker.GetParent(element); + } - //menuItem.GetInvokePattern().Invoke(); + if (menuItem != null) + { + var inv = menuItem.GetInvokePattern() ?? element.GetInvokePattern(); + if (inv != null) + { + inv.Invoke(); + } + } + } WaitForTestsGrid(); } - private void WaitForTestsGrid() { + private void WaitForTestsGrid() + { // Wait for the test list to be created int retry = 10; - while (Tests == null) { + while (Tests == null) + { Thread.Sleep(250); retry--; - if (retry == 0) { + if (retry == 0) + { break; } } Assert.IsNotNull(Tests, "Tests list is null"); } - public void ClearSearchBar() { + public void ClearSearchBar() + { _searchBar.SetValue(""); Thread.Sleep(1000); } - public AutomationElement WaitForItem(params string[] path) { + public AutomationElement WaitForItem(params string[] path) + { // WaitForItem doesn't work well with offscreen items // so we use the search bar to filter by function name to // limit the items on screen and then expand all tree items. @@ -183,7 +219,8 @@ public AutomationElement WaitForItem(params string[] path) { // it multiple times with delay as a work around. _searchBar.SetValue(path[path.Length - 1]); - for (int i = 0; i < path.Length + 2; i++) { + for (int i = 0; i < path.Length + 2; i++) + { Tests.ExpandAll(); } @@ -193,7 +230,8 @@ public AutomationElement WaitForItem(params string[] path) { /// /// Run all tests and wait for the command to be available again. /// - public void RunAll(TimeSpan timeout) { + public void RunAll(TimeSpan timeout) + { ClearSearchBar(); _app.Dte.ExecuteCommand(TestCommands.RunAllTests); Thread.Sleep(100); @@ -203,7 +241,8 @@ public void RunAll(TimeSpan timeout) { /// /// Debug all tests and wait for the command to be available again. /// - public void DebugAll() { + public void DebugAll() + { _app.Dte.ExecuteCommand(TestCommands.DebugAllTests); Thread.Sleep(100); } diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index e4c805d11a..ad7695745d 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -10,7 +10,7 @@ resources: # All PTVS build artifacts come from this pipeline and are referenced like this: # $(Pipeline.Workspace)\ComponentBuildUnderTest\\ - pipeline: ComponentBuildUnderTest - source: PTVS-Build-Dev17 + source: PTVS-Build branch: main # This is only used for manual/scheduled runs of this pipeline trigger: branches: From 5f28f045892f1b78649774fbf9cf768442bd2d1f Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 3 Dec 2025 18:19:27 -0800 Subject: [PATCH 02/75] update ComponentBuildUnderTest --- azure-pipelines-integration-tests.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index ad7695745d..42a902f996 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -10,7 +10,8 @@ resources: # All PTVS build artifacts come from this pipeline and are referenced like this: # $(Pipeline.Workspace)\ComponentBuildUnderTest\\ - pipeline: ComponentBuildUnderTest - source: PTVS-Build + project: DevDiv + source: Python\PTVS\PTVS-Build branch: main # This is only used for manual/scheduled runs of this pipeline trigger: branches: From e1ac46b2c1c544b3750af0118388780c8a8a4ea8 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 09:26:11 -0800 Subject: [PATCH 03/75] try uploading test data to azure artifacts --- azure-pipelines.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 2d7b2e49aa..881ec5fa8f 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -158,6 +158,13 @@ extends: codeSignValidation: enabled: false outputs: + - output: artifactsDrop + displayName: 'Upload Test Data to Artifact Services' + dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' + buildNumber: PTVS\$(Build.SourceBranchName)\$(Build.BuildNumber) + sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' + detailedLog: true + toLowerCase: false - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' From 25176cad9acd84f1924d82bf598a3ed035a04144 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 09:42:05 -0800 Subject: [PATCH 04/75] disable codeql if not commit in main or release --- azure-pipelines.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 881ec5fa8f..47d4ca9795 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -155,6 +155,12 @@ extends: # Disable code signing validation because we don't ship ANY of the artifacts that we publish. # The only released artifacts are uploaded via the 1ES.MicroBuildVstsDrop@1 below. sdl: + codeql: + # disable if not commit in main or release + ${{ if or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'], 'refs/heads/release/')) }}: + enabled: true + ${{ else }}: + enabled: false codeSignValidation: enabled: false outputs: From 039f680473860d585d4fe924b1a48e2cc8be1d61 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 09:44:25 -0800 Subject: [PATCH 05/75] faster checkout --- azure-pipelines.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 47d4ca9795..279e505c0b 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -211,6 +211,7 @@ extends: # check out code clean from source control - checkout: self clean: true + fetchDepth: 1 # Non-PR steps - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: @@ -279,3 +280,6 @@ extends: + + + From 8f976144ee5338c69fe72e94365f76e5a1189d54 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 12:34:56 -0800 Subject: [PATCH 06/75] try to skip signing when building installer --- Build/templates/build.yml | 4 ++++ Python/Setup/signlayout.proj | 22 +++++++++++++--------- azure-pipelines.yml | 13 +++++++++++++ 3 files changed, 30 insertions(+), 9 deletions(-) diff --git a/Build/templates/build.yml b/Build/templates/build.yml index 9d755e9134..94e05dd21b 100644 --- a/Build/templates/build.yml +++ b/Build/templates/build.yml @@ -2,6 +2,9 @@ parameters: - name: ptvsPackageVersion type: string default: $(Build.BuildNumber) +- name: skipSigning + type: boolean + default: false steps: @@ -57,4 +60,5 @@ steps: /p:BuildNumber=${{ parameters.ptvsPackageVersion }} /p:BUILD_BINARIESDIRECTORY=$(Build.BinariesDirectory) /p:BUILD_STAGINGDIRECTORY=$(Build.StagingDirectory) + /p:SkipSigning=${{ parameters.skipSigning }} /bl:$(Build.SourcesDirectory)\logs\BuildInstaller.binlog' diff --git a/Python/Setup/signlayout.proj b/Python/Setup/signlayout.proj index 4f2f5ff6b6..23cf5cf63c 100644 --- a/Python/Setup/signlayout.proj +++ b/Python/Setup/signlayout.proj @@ -9,6 +9,10 @@ $(BinariesOutputPath) $(BinariesOutputPath) + + false + + None @@ -17,7 +21,7 @@ - + <_Languages Include="$(Languages)" /> + @@ -84,7 +88,7 @@ - + @@ -96,17 +100,17 @@ - + - + - + <_BinariesInLayout Include="$(LayoutOutputPath)**\*.exe;$(LayoutOutputPath)**\*.dll" /> <_BinariesWithSignedSource Include="$(BinariesOutputPath)%(_BinariesInLayout.Filename)%(_BinariesInLayout.Extension)"> @@ -116,7 +120,7 @@ - + <_FilesInLayout Include="$(LayoutOutputPath)\Microsoft.PythonTools.Core\pylance\**\*.js" /> @@ -127,10 +131,10 @@ - + AfterTargets="SignFiles" + Condition="'$(SkipSigning)'!='true'"> diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 279e505c0b..2db1afb90d 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -41,6 +41,11 @@ parameters: type: boolean default: false +- name: skipSigning + displayName: Skip Signing + type: boolean + default: false + # build number format name: $(date:yy)$(DayOfYear)$(rev:.r) @@ -118,6 +123,13 @@ variables: ${{ else }}: value: ${{ parameters.ptvsPackageVersion }} + # Skip signing for PR builds by default, use parameter override for manual builds + - name: skipSigningVar + ${{ if eq(variables['Build.Reason'], 'PullRequest') }}: + value: true + ${{ else }}: + value: ${{ parameters.skipSigning }} + # Import variables from PTVS-Dev18 variable group - group: PTVS-Dev17 @@ -234,6 +246,7 @@ extends: - template: /Build/templates/build.yml@self parameters: ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} + skipSigning: ${{ variables.skipSigningVar }} # Non-PR steps - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: From 4971b2168ce3fae830f14a7e2afd337d1e25534e Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 13:30:17 -0800 Subject: [PATCH 07/75] disable sbom --- azure-pipelines.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 2db1afb90d..8d1489df24 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -175,6 +175,8 @@ extends: enabled: false codeSignValidation: enabled: false + sbom: + enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - output: artifactsDrop displayName: 'Upload Test Data to Artifact Services' From 80f7ce50f5087b9c530005d20a1aba52c0edfbe4 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 13:37:24 -0800 Subject: [PATCH 08/75] add persistCredentials: true --- azure-pipelines.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 8d1489df24..2cead257ad 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -226,6 +226,7 @@ extends: - checkout: self clean: true fetchDepth: 1 + persistCredentials: true # Non-PR steps - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: From ec63b1c242bd931d436cb84859c0d6e039b784e3 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 14:07:16 -0800 Subject: [PATCH 09/75] move testdata to its own job for faster testing --- azure-pipelines.yml | 55 ++++++++++++++++++++++++++++++--------------- 1 file changed, 37 insertions(+), 18 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 2cead257ad..eab7e4f788 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -178,13 +178,7 @@ extends: sbom: enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - - output: artifactsDrop - displayName: 'Upload Test Data to Artifact Services' - dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildNumber: PTVS\$(Build.SourceBranchName)\$(Build.BuildNumber) - sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' - detailedLog: true - toLowerCase: false + - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' @@ -198,17 +192,7 @@ extends: displayName: 'Publish build artifact: logs' condition: succeededOrFailed() targetPath: '$(Build.SourcesDirectory)\logs' - artifactName: Logs - - output: pipelineArtifact - displayName: 'Publish build artifact: TestData' - targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' - sbomBuildDropPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder' - artifactName: 'TestData' - - output: pipelineArtifact - displayName: 'Publish build artifact: RunSettings' - targetPath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' - sbomBuildDropPath: '$(Build.SourcesDirectory)/Python/Tests/TestData' - artifactName: 'RunSettings' + artifactName: Logs - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: - output: pipelineArtifact displayName: 'Publish build artifact: BoM' @@ -281,6 +265,41 @@ extends: displayName: 'Execute cleanup tasks' condition: succeededOrFailed() + # Separate job for TestData generation - runs in parallel with build job + - job: testdata + displayName: Publish TestData + templateContext: + sdl: + codeSignValidation: + enabled: false + sbom: + enabled: false + outputs: + - output: artifactsDrop + displayName: 'Upload Test Data to Artifact Services' + dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' + buildNumber: PTVS\$(Build.SourceBranchName)\$(Build.BuildNumber) + sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' + detailedLog: true + toLowerCase: false + - output: pipelineArtifact + displayName: 'Publish build artifact: TestData' + targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' + sbomBuildDropPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder' + artifactName: 'TestData' + - output: pipelineArtifact + displayName: 'Publish build artifact: RunSettings' + targetPath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' + sbomBuildDropPath: '$(Build.SourcesDirectory)/Python/Tests/TestData' + artifactName: 'RunSettings' + + steps: + # check out code clean from source control + - checkout: self + clean: true + fetchDepth: 1 + prersistCredentials: true + # Publish test data - template: /Build/templates/publish_test_data.yml@self From cd09e071df8da24acd93fa3bcd7f403ed5ce478e Mon Sep 17 00:00:00 2001 From: Bill Schnurr Date: Thu, 4 Dec 2025 14:15:59 -0800 Subject: [PATCH 10/75] Update azure-pipelines.yml for Azure Pipelines --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index eab7e4f788..c9caff36c7 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -298,7 +298,7 @@ extends: - checkout: self clean: true fetchDepth: 1 - prersistCredentials: true + persistCredentials: true # Publish test data - template: /Build/templates/publish_test_data.yml@self From f1b8425e9ba70b5b00c6d90a098a8038f621bbca Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 4 Dec 2025 17:45:04 -0800 Subject: [PATCH 11/75] try adding a container name and pat flag --- azure-pipelines.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index eab7e4f788..0c86ab38d8 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -278,9 +278,11 @@ extends: - output: artifactsDrop displayName: 'Upload Test Data to Artifact Services' dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildNumber: PTVS\$(Build.SourceBranchName)\$(Build.BuildNumber) + buildNumber: $(Build.SourceBranchName)\$(Build.BuildNumber) sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' + dropMetadataContainerName: PTVS-TestData detailedLog: true + usePat: true toLowerCase: false - output: pipelineArtifact displayName: 'Publish build artifact: TestData' From 0294244ee4b5cfbe5018597d56108f1b0257110e Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 10:05:01 -0800 Subject: [PATCH 12/75] remove slash in buildNumber --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 18aad1d9cd..82152fc434 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -278,7 +278,7 @@ extends: - output: artifactsDrop displayName: 'Upload Test Data to Artifact Services' dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildNumber: $(Build.SourceBranchName)\$(Build.BuildNumber) + buildNumber: $(Build.SourceBranchName).$(Build.BuildNumber) sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' dropMetadataContainerName: PTVS-TestData detailedLog: true From 122e6e0f0b38e8ddcb332938dd040b96a4a3ca02 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 10:43:45 -0800 Subject: [PATCH 13/75] try folder --- azure-pipelines.yml | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 82152fc434..c617f834bf 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -276,14 +276,18 @@ extends: enabled: false outputs: - output: artifactsDrop - displayName: 'Upload Test Data to Artifact Services' - dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildNumber: $(Build.SourceBranchName).$(Build.BuildNumber) - sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' + sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder + dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ dropMetadataContainerName: PTVS-TestData - detailedLog: true - usePat: true - toLowerCase: false + # - output: artifactsDrop + # displayName: 'Upload Test Data to Artifact Services' + # dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' + # buildNumber: $(Build.SourceBranchName).$(Build.BuildNumber) + # sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' + # dropMetadataContainerName: PTVS-TestData + # detailedLog: true + # usePat: true + # toLowerCase: false - output: pipelineArtifact displayName: 'Publish build artifact: TestData' targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' From 118a12801c2bf4ae4896783ee3861c2ccebef721 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 11:03:49 -0800 Subject: [PATCH 14/75] add display name --- azure-pipelines.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index c617f834bf..4e23927739 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -276,6 +276,7 @@ extends: enabled: false outputs: - output: artifactsDrop + displayName: 'Upload Test Data to Artifact Services' sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ dropMetadataContainerName: PTVS-TestData From aa05ad8906a669db8728b18fd2f88dfa9e9c341d Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 11:30:54 -0800 Subject: [PATCH 15/75] try using isProduction: false to disable sdl --- azure-pipelines.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 4e23927739..29f8746a27 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -164,6 +164,7 @@ extends: # If the pipeline publishes artifacts, use `templateContext` to define the artifacts. # This will enable 1ES PT to run SDL analysis tools on the artifacts and then upload them. templateContext: + isProduction: false # Disable code signing validation because we don't ship ANY of the artifacts that we publish. # The only released artifacts are uploaded via the 1ES.MicroBuildVstsDrop@1 below. sdl: @@ -269,6 +270,7 @@ extends: - job: testdata displayName: Publish TestData templateContext: + isProduction: false sdl: codeSignValidation: enabled: false From 66bc70a13fe7e274c207dadc75de2189b29f66c4 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 13:50:15 -0800 Subject: [PATCH 16/75] try to download testdata --- azure-pipelines-integration-tests.yml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index 42a902f996..bfe746c33e 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -50,10 +50,10 @@ stages: # as the machine running the actual tests preTestMachineConfigurationStepList: - - download: ComponentBuildUnderTest - artifact: MicroBuildOutputs - patterns: '**\BootstrapperInfo.json' - displayName: Download Bootstrapper Information + # - download: ComponentBuildUnderTest + # artifact: MicroBuildOutputs + # patterns: '**\BootstrapperInfo.json' + # displayName: Download Bootstrapper Information - download: ComponentBuildUnderTest artifact: RunSettings @@ -74,3 +74,12 @@ stages: artifact: RunSettings patterns: '**\default.runsettings' displayName: Download RunSettings + + - task: ArtifactDropDownloadTask@1 + displayName: 'Download TestData from Artifacts Drop' + inputs: + dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' + buildNumber: '$(resources.pipeline.ComponentBuildUnderTest.sourceBranch).$(resources.pipeline.ComponentBuildUnderTest.runName)' + dropMetadataContainerName: 'PTVS-TestData' + destinationPath: '$(Pipeline.Workspace)/TestData' + usePat: false From 6e973d15f52bfc5fb608839612c741c7f80c0a8b Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 14:13:24 -0800 Subject: [PATCH 17/75] change location of artifact download --- azure-pipelines-integration-tests.yml | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index bfe746c33e..e7f0bc2776 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -54,6 +54,16 @@ stages: # artifact: MicroBuildOutputs # patterns: '**\BootstrapperInfo.json' # displayName: Download Bootstrapper Information + + - task: ArtifactDropDownloadTask@1 + displayName: 'Download TestData from Artifacts Drop' + inputs: + dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' + buildNumber: '$(resources.pipeline.ComponentBuildUnderTest.sourceBranch).$(resources.pipeline.ComponentBuildUnderTest.runName)' + dropMetadataContainerName: 'PTVS-TestData' + destinationPath: '$(Pipeline.Workspace)/TestData' + usePat: false + - download: ComponentBuildUnderTest artifact: RunSettings @@ -75,11 +85,4 @@ stages: patterns: '**\default.runsettings' displayName: Download RunSettings - - task: ArtifactDropDownloadTask@1 - displayName: 'Download TestData from Artifacts Drop' - inputs: - dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildNumber: '$(resources.pipeline.ComponentBuildUnderTest.sourceBranch).$(resources.pipeline.ComponentBuildUnderTest.runName)' - dropMetadataContainerName: 'PTVS-TestData' - destinationPath: '$(Pipeline.Workspace)/TestData' - usePat: false + \ No newline at end of file From 78f7ca2dbed982e2d75356d63609ce52d1a780c5 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 14:27:58 -0800 Subject: [PATCH 18/75] try runId with metadata name --- azure-pipelines-integration-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index e7f0bc2776..78082668db 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -59,7 +59,7 @@ stages: displayName: 'Download TestData from Artifacts Drop' inputs: dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildNumber: '$(resources.pipeline.ComponentBuildUnderTest.sourceBranch).$(resources.pipeline.ComponentBuildUnderTest.runName)' + buildId: '$(resources.pipeline.ComponentBuildUnderTest.runId)' dropMetadataContainerName: 'PTVS-TestData' destinationPath: '$(Pipeline.Workspace)/TestData' usePat: false From 1d406ad86c4babac53c46c8940463ac40db5afa8 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 14:58:05 -0800 Subject: [PATCH 19/75] try sourceRunId --- azure-pipelines-integration-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index 78082668db..3653a9ea8e 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -59,9 +59,9 @@ stages: displayName: 'Download TestData from Artifacts Drop' inputs: dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - buildId: '$(resources.pipeline.ComponentBuildUnderTest.runId)' + sourceRunId: $(resources.pipeline.ComponentBuildUnderTest.runId) dropMetadataContainerName: 'PTVS-TestData' - destinationPath: '$(Pipeline.Workspace)/TestData' + destinationPath: '$(Pipeline.Workspace)/TestData' usePat: false From b5cb564785acabd61380fd5f51e36810dc0df8fb Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 15:11:08 -0800 Subject: [PATCH 20/75] try dropMetadataContainerBuild --- azure-pipelines-integration-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index 3653a9ea8e..b943c53a72 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -59,9 +59,9 @@ stages: displayName: 'Download TestData from Artifacts Drop' inputs: dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - sourceRunId: $(resources.pipeline.ComponentBuildUnderTest.runId) + dropMetadataContainerBuild: $(resources.pipeline.ComponentBuildUnderTest.runId) dropMetadataContainerName: 'PTVS-TestData' - destinationPath: '$(Pipeline.Workspace)/TestData' + destinationPath: '$(Pipeline.Workspace)/TestData' usePat: false From 2ff23cbd009d722c673fe4f5d94c6cfb8a3a99de Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 15:26:57 -0800 Subject: [PATCH 21/75] remove usePat false.. we need a PAT --- azure-pipelines-integration-tests.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index b943c53a72..822b2cb3ac 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -61,8 +61,7 @@ stages: dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' dropMetadataContainerBuild: $(resources.pipeline.ComponentBuildUnderTest.runId) dropMetadataContainerName: 'PTVS-TestData' - destinationPath: '$(Pipeline.Workspace)/TestData' - usePat: false + destinationPath: '$(Pipeline.Workspace)/TestData' - download: ComponentBuildUnderTest From 30f2b94bf3c1d5f06b5ad6cbd5c940125ddfc11a Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 15:43:23 -0800 Subject: [PATCH 22/75] remove commenrts --- azure-pipelines.yml | 9 --------- 1 file changed, 9 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 29f8746a27..44d4501a61 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -282,15 +282,6 @@ extends: sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ dropMetadataContainerName: PTVS-TestData - # - output: artifactsDrop - # displayName: 'Upload Test Data to Artifact Services' - # dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - # buildNumber: $(Build.SourceBranchName).$(Build.BuildNumber) - # sourcePath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' - # dropMetadataContainerName: PTVS-TestData - # detailedLog: true - # usePat: true - # toLowerCase: false - output: pipelineArtifact displayName: 'Publish build artifact: TestData' targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' From 1a4b42e7f4b9f842394e5b2f62c84ef99711e838 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 17:05:27 -0800 Subject: [PATCH 23/75] try uploading RunSettings --- azure-pipelines.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 44d4501a61..d6f4b0a8e1 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -282,15 +282,18 @@ extends: sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ dropMetadataContainerName: PTVS-TestData + - output: artifactsDrop + displayName: 'RunSettings to Artifact Services' + sourcePath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' + dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + dropMetadataContainerName: PTVS-RunSettings - output: pipelineArtifact displayName: 'Publish build artifact: TestData' targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' - sbomBuildDropPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder' artifactName: 'TestData' - output: pipelineArtifact displayName: 'Publish build artifact: RunSettings' - targetPath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' - sbomBuildDropPath: '$(Build.SourcesDirectory)/Python/Tests/TestData' + targetPath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' artifactName: 'RunSettings' steps: From d8e33599b3e2312f2e7b750498bbec519725a2fa Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 5 Dec 2025 17:31:16 -0800 Subject: [PATCH 24/75] just copy default.runsettings to the folder we are already uploading. `artifactsDrop` task doesn't support files --- azure-pipelines.yml | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index d6f4b0a8e1..b735cd6768 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -277,16 +277,11 @@ extends: sbom: enabled: false outputs: - - output: artifactsDrop + - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline displayName: 'Upload Test Data to Artifact Services' sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - dropMetadataContainerName: PTVS-TestData - - output: artifactsDrop - displayName: 'RunSettings to Artifact Services' - sourcePath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' - dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - dropMetadataContainerName: PTVS-RunSettings + dropMetadataContainerName: PTVS-TestData - output: pipelineArtifact displayName: 'Publish build artifact: TestData' targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' @@ -306,6 +301,14 @@ extends: # Publish test data - template: /Build/templates/publish_test_data.yml@self + # Copy runsettings to TestDataFolder for azure_pipelines_integration_tests.yml pipeline + - task: CopyFiles@2 + displayName: 'Copy runsettings to TestDataFolder' + inputs: + SourceFolder: '$(Build.SourcesDirectory)/Python/Tests/TestData' + Contents: 'default.runsettings' + TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' + # Run tests on mixed mode debugger but only for PR builds # - ${{ if or(eq(variables['Build.Reason'], 'PullRequest'), eq(variables['SkipGlassCache'], true)) }}: # - job: test From d0a770c9e75ae9db1f28c8ff9a9eb8ca30269c23 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 8 Dec 2025 13:59:37 -0800 Subject: [PATCH 25/75] update Bootstrapper to artifacts --- azure-pipelines.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index b735cd6768..ce2e2ef3ed 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -179,7 +179,11 @@ extends: sbom: enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - + - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + displayName: 'Upload Bootstrapper to Artifact Services' + sourcePath: $(Build.StagingDirectory)\release\bootstrapper + dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + dropMetadataContainerName: PTVS-Bootstrapper - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' From 821ce997e68c325352ac927581439ef7a45b8b33 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 8 Dec 2025 14:28:33 -0800 Subject: [PATCH 26/75] change to MicroBuild output folder --- azure-pipelines.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index ce2e2ef3ed..1ec643390c 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -180,10 +180,10 @@ extends: enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - displayName: 'Upload Bootstrapper to Artifact Services' - sourcePath: $(Build.StagingDirectory)\release\bootstrapper + displayName: 'Upload MicroBuild to Artifact Services' + sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - dropMetadataContainerName: PTVS-Bootstrapper + dropMetadataContainerName: PTVS-MicroBuild - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' From 95c5b9e2bd14f2fed498013f645cbb47433db7b2 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 8 Dec 2025 16:03:09 -0800 Subject: [PATCH 27/75] customize buildnumber for artifacts drop so that there is no conflict between testdata and bootloader --- azure-pipelines.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 1ec643390c..7ed6c62194 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -161,6 +161,8 @@ extends: # Set pipeline timeout to 2 hours (120 minutes) timeoutInMinutes: 120 displayName: Build + variables: + BootloaderDropName: 'Bootloader/$(System.TeamProject)/$(Build.Repository.Name)/$(SourceBranch)/$(Build.BuildId)' # If the pipeline publishes artifacts, use `templateContext` to define the artifacts. # This will enable 1ES PT to run SDL analysis tools on the artifacts and then upload them. templateContext: @@ -183,7 +185,8 @@ extends: displayName: 'Upload MicroBuild to Artifact Services' sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - dropMetadataContainerName: PTVS-MicroBuild + dropMetadataContainerName: PTVS-Bootloader + buildNumber: '$(BootloaderDropName)' - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' @@ -273,6 +276,8 @@ extends: # Separate job for TestData generation - runs in parallel with build job - job: testdata displayName: Publish TestData + variables: + TestDataDropName: 'TestData/$(System.TeamProject)/$(Build.Repository.Name)/$(SourceBranch)/$(Build.BuildId)' templateContext: isProduction: false sdl: @@ -285,6 +290,7 @@ extends: displayName: 'Upload Test Data to Artifact Services' sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + buildNumber: '$(TestDataDropName)' dropMetadataContainerName: PTVS-TestData - output: pipelineArtifact displayName: 'Publish build artifact: TestData' From 36d0b0017f5233d024db8c0a1d6dfadced7a32e7 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 8 Dec 2025 16:33:22 -0800 Subject: [PATCH 28/75] try fixing buildNumber artifactsDrop --- azure-pipelines.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 7ed6c62194..e163807d6d 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -162,7 +162,7 @@ extends: timeoutInMinutes: 120 displayName: Build variables: - BootloaderDropName: 'Bootloader/$(System.TeamProject)/$(Build.Repository.Name)/$(SourceBranch)/$(Build.BuildId)' + BootloaderDropName: 'Bootloader/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)' # If the pipeline publishes artifacts, use `templateContext` to define the artifacts. # This will enable 1ES PT to run SDL analysis tools on the artifacts and then upload them. templateContext: @@ -277,7 +277,7 @@ extends: - job: testdata displayName: Publish TestData variables: - TestDataDropName: 'TestData/$(System.TeamProject)/$(Build.Repository.Name)/$(SourceBranch)/$(Build.BuildId)' + TestDataDropName: 'TestData/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)' templateContext: isProduction: false sdl: From b0ea8725a73050260b4de7eb24c2bab8f361c20e Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 8 Dec 2025 18:17:50 -0800 Subject: [PATCH 29/75] try chanigng bootloader folder to match output folder of MicroBuildBuildVSBootstrapper --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index e163807d6d..d58fe81bbc 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -183,7 +183,7 @@ extends: outputs: - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline displayName: 'Upload MicroBuild to Artifact Services' - sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + sourcePath: $(Build.StagingDirectory)\release dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ dropMetadataContainerName: PTVS-Bootloader buildNumber: '$(BootloaderDropName)' From f1181a998cbf73192eff0da3aa9522cf815f1c2a Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 8 Dec 2025 22:49:09 -0800 Subject: [PATCH 30/75] try microbuild output with pipeline artifact --- azure-pipelines.yml | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index d58fe81bbc..30491ea79a 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -1,4 +1,4 @@ -# This pipeline is used to build the PTVS product and installer. +# This pipeline is used to build the PTVS product and installer. # A seperate release pipeline is used to create insertion PR's into Visual Studio. # The pipeline extends v1/1ES.Official.PipelineTemplate.yml@1ESPipelineTemplates from 1esPipelines repository defined in resources section. @@ -181,12 +181,16 @@ extends: sbom: enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - displayName: 'Upload MicroBuild to Artifact Services' - sourcePath: $(Build.StagingDirectory)\release - dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - dropMetadataContainerName: PTVS-Bootloader - buildNumber: '$(BootloaderDropName)' + # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + # displayName: 'Upload MicroBuild to Artifact Services' + # sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + # dropMetadataContainerName: PTVS-Bootloader + # buildNumber: '$(BootloaderDropName)' + - output: pipelineArtifact + displayName: 📢 Publish MicroBuildOutputs + targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + artifactName: MicroBuildOutputs - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' From d0a9f7d1d4c90436428f795500d2dcc268332f18 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 9 Dec 2025 09:22:58 -0800 Subject: [PATCH 31/75] download microbuildoutputs --- azure-pipelines-integration-tests.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index 822b2cb3ac..56e5e24cd7 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -50,10 +50,10 @@ stages: # as the machine running the actual tests preTestMachineConfigurationStepList: - # - download: ComponentBuildUnderTest - # artifact: MicroBuildOutputs - # patterns: '**\BootstrapperInfo.json' - # displayName: Download Bootstrapper Information + - download: ComponentBuildUnderTest + artifact: MicroBuildOutputs + patterns: '**\BootstrapperInfo.json' + displayName: Download Bootstrapper Information - task: ArtifactDropDownloadTask@1 displayName: 'Download TestData from Artifacts Drop' From f7cac4c2f79ee42ddc00b29a3b715315d792d546 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 9 Dec 2025 10:33:28 -0800 Subject: [PATCH 32/75] try using artifactsDrop for MicroBuildOutputs --- azure-pipelines.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 30491ea79a..d39f56e03a 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -181,16 +181,16 @@ extends: sbom: enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - # displayName: 'Upload MicroBuild to Artifact Services' - # sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output - # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - # dropMetadataContainerName: PTVS-Bootloader - # buildNumber: '$(BootloaderDropName)' - - output: pipelineArtifact - displayName: 📢 Publish MicroBuildOutputs - targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output - artifactName: MicroBuildOutputs + - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + displayName: 'Upload MicroBuild to Artifact Services' + sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + dropMetadataContainerName: MicroBuildOutputs + buildNumber: '$(BootloaderDropName)' + # - output: pipelineArtifact + # displayName: 📢 Publish MicroBuildOutputs + # targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + # artifactName: MicroBuildOutputs - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' From 7afbe8fabb9bcb9b9a8ec5e88abbc7f24e56a216 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 9 Dec 2025 12:01:42 -0800 Subject: [PATCH 33/75] use pipelineartifact for now --- azure-pipelines-integration-tests.yml | 3 ++- azure-pipelines.yml | 22 +++++++++++----------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index 56e5e24cd7..aeb0ca0e25 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -2,7 +2,8 @@ trigger: none pr: none -# For more info about how this resources section works, see https://docs.microsoft.com/en-us/azure/devops/pipelines/process/resources?view=azure-devops&tabs=schema +# The following steps describe how to create a DartLab pipeline that installs Visual Studio using a bootstrapper generated by the MicroBuild Build VS Bootstrapper task +# in the component repo's MicroBuild: https://dev.azure.com/devdiv/DevDiv/_wiki/wikis/DevDiv.wiki/45681/Component-Repository resources: pipelines: diff --git a/azure-pipelines.yml b/azure-pipelines.yml index d39f56e03a..539a8c776f 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -181,16 +181,16 @@ extends: sbom: enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output outputs: - - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - displayName: 'Upload MicroBuild to Artifact Services' - sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output - dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - dropMetadataContainerName: MicroBuildOutputs - buildNumber: '$(BootloaderDropName)' - # - output: pipelineArtifact - # displayName: 📢 Publish MicroBuildOutputs - # targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output - # artifactName: MicroBuildOutputs + # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + # displayName: 'Upload MicroBuild to Artifact Services' + # sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + # dropMetadataContainerName: MicroBuildOutputs + # buildNumber: '$(BootloaderDropName)' + - output: pipelineArtifact + displayName: 📢 Publish MicroBuildOutputs + targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + artifactName: MicroBuildOutputs - output: pipelineArtifact displayName: 'Publish build artifact: binaries' targetPath: '$(Build.BinariesDirectory)/raw/binaries' @@ -294,7 +294,7 @@ extends: displayName: 'Upload Test Data to Artifact Services' sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - buildNumber: '$(TestDataDropName)' + # buildNumber: '$(TestDataDropName)' dropMetadataContainerName: PTVS-TestData - output: pipelineArtifact displayName: 'Publish build artifact: TestData' From 2923b84eac1272ddc649e7aca9e19691ecbf73bb Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 10 Dec 2025 10:05:06 -0800 Subject: [PATCH 34/75] update to new test machines --- azure-pipelines-integration-tests.yml | 50 ++++++++++----------------- 1 file changed, 18 insertions(+), 32 deletions(-) diff --git a/azure-pipelines-integration-tests.yml b/azure-pipelines-integration-tests.yml index aeb0ca0e25..4757a046e6 100644 --- a/azure-pipelines-integration-tests.yml +++ b/azure-pipelines-integration-tests.yml @@ -34,55 +34,41 @@ resources: stages: -- template: stages/visual-studio/single-runsettings.yml@DartLabTemplates +- template: stages/cloudtest/visual-studio/single-runsettings.yml@DartLabTemplates parameters: displayName: Integration Tests - variables: - - name: VisualStudio.InstallationUnderTest.BootstrapperBranch - value: main - testLabPoolName: Azure-and-Web - testMachineTotalCount: 1 + owner: ptvs + testMachineLab: DDRITs-PR # This assumes the PTVS build has published a build artifact called "RunSettings" that contains the default.runsettings file - runSettingsURI: $(Pipeline.Workspace)\ComponentBuildUnderTest\RunSettings\default.runsettings + runSettingsURI: https://vsdrop.microsoft.com/file/v1/$(RunSettings.DropName);default.runsettings visualStudioBootstrapperURI: $(VisualStudio.InstallationUnderTest.BootstrapperURL) visualStudioSigning: Test - + testMachineConfigurationJobVariables: + - name: VisualStudio.InstallationUnderTest.BootstrapperBranch + value: main # These steps run on the machine that is creating the test machine configuration, which isn't the same # as the machine running the actual tests - preTestMachineConfigurationStepList: - + preTestMachineConfigurationSteps: + - download: ComponentBuildUnderTest artifact: MicroBuildOutputs patterns: '**\BootstrapperInfo.json' displayName: Download Bootstrapper Information - - task: ArtifactDropDownloadTask@1 - displayName: 'Download TestData from Artifacts Drop' - inputs: - dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - dropMetadataContainerBuild: $(resources.pipeline.ComponentBuildUnderTest.runId) - dropMetadataContainerName: 'PTVS-TestData' - destinationPath: '$(Pipeline.Workspace)/TestData' - - - - download: ComponentBuildUnderTest - artifact: RunSettings - patterns: '**\default.runsettings' - displayName: Download RunSettings - - task: PowerShell@2 displayName: Set 'VisualStudio.InstallationUnderTest.BootstrapperURL' inputs: filePath: $(DartLab.Path)\Scripts\VisualStudio\Bootstrapper\Get-BootstrapperURL.ps1 - # This assumes the PTVS build has published a build artifact called "MicroBuildOutputs" that contains the generated BootstrapperInfo.json arguments: -BootstrapperInfoJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\MicroBuildOutputs\BootstrapperInfo.json' -VSBranch '$(VisualStudio.InstallationUnderTest.BootstrapperBranch)' -OutVariableName 'VisualStudio.InstallationUnderTest.BootstrapperURL' - - # These steps run on the machine that is running the tests - preDeployAndRunTestsStepList: - download: ComponentBuildUnderTest - artifact: RunSettings - patterns: '**\default.runsettings' - displayName: Download RunSettings + artifact: PTVS-TestData + patterns: '**\VSTSDrop.json' + displayName: Download drop Information - \ No newline at end of file + - template: \steps\powershell\execute-script.yml@DartLabTemplates + parameters: + displayName: Set 'RunSettings.DropName' + filePath: $(DartLab.Path)\Scripts\AzureDevOps\Artifacts\Drop\Get-DropName.ps1 + arguments: -VSTSDropJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\PTVS-TestData\VSTSDrop.json' -OutVariableName 'RunSettings.DropName' + \ No newline at end of file From cd762bb496bbe850e8f7d6073943b82648d0767a Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 10 Dec 2025 13:49:05 -0800 Subject: [PATCH 35/75] add runsettingsproj --- Build/18.0/packages.config | 1 + Build/PreBuild.ps1 | 2 +- Build/nuget.config | 1 + Python/PythonTools.sln | 7 +++++-- Python/Tests/PTVS.runsettingsproj | 29 +++++++++++++++++++++++++++++ package.json | 2 +- 6 files changed, 38 insertions(+), 4 deletions(-) create mode 100644 Python/Tests/PTVS.runsettingsproj diff --git a/Build/18.0/packages.config b/Build/18.0/packages.config index 1c79198ef1..ce411012c0 100644 --- a/Build/18.0/packages.config +++ b/Build/18.0/packages.config @@ -83,4 +83,5 @@ + diff --git a/Build/PreBuild.ps1 b/Build/PreBuild.ps1 index 2f7b908c2c..c16482782b 100644 --- a/Build/PreBuild.ps1 +++ b/Build/PreBuild.ps1 @@ -208,7 +208,7 @@ try { if (-not $interactive) { $arglist += "-NonInteractive" } - $nuget = Get-Command nuget.exe -EA 0 + $nuget = Get-Command .\nuget.exe -EA 0 if (-not $nuget) { $nuget = Get-Command .\nuget.exe } diff --git a/Build/nuget.config b/Build/nuget.config index 5dd8ead95c..842230ada0 100644 --- a/Build/nuget.config +++ b/Build/nuget.config @@ -6,6 +6,7 @@ + diff --git a/Python/PythonTools.sln b/Python/PythonTools.sln index 26958ebab1..4b69ac133e 100644 --- a/Python/PythonTools.sln +++ b/Python/PythonTools.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 17 -VisualStudioVersion = 17.0.31211.46 +# Visual Studio Version 18 +VisualStudioVersion = 18.3.11227.31 main MinimumVisualStudioVersion = 10.0.40219.1 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Product", "Product", "{C0C7AD6F-5E39-4D3F-A6B6-FD30713B0464}" EndProject @@ -16,6 +16,9 @@ EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TestUtilities.UI", "..\Common\Tests\Utilities.UI\TestUtilities.UI.csproj", "{E8150EBC-6B62-40BF-BF91-1DC60149B530}" EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{3D21C7AC-6F9D-448C-8356-44EAFB2D14FC}" + ProjectSection(SolutionItems) = preProject + Tests\PTVS.runsettingsproj = Tests\PTVS.runsettingsproj + EndProjectSection EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Attacher", "Product\Attacher\Attacher.csproj", "{666A22BB-0CB5-4C08-A20F-E17450DA6573}" EndProject diff --git a/Python/Tests/PTVS.runsettingsproj b/Python/Tests/PTVS.runsettingsproj new file mode 100644 index 0000000000..f4d0a25f85 --- /dev/null +++ b/Python/Tests/PTVS.runsettingsproj @@ -0,0 +1,29 @@ + + + + net472 + DDRITs + bin\RunSettings + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/package.json b/package.json index befda4439b..30b28f16c4 100644 --- a/package.json +++ b/package.json @@ -2,6 +2,6 @@ "name": "ptvs", "private": true, "devDependencies": { - "@pylance/pylance": "2025.9.1" + "@pylance/pylance": "2025.10.4" } } From d37d2233d0b43ac0aa3f338914064fab1f7ef17e Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 28 Jan 2026 15:51:39 -0800 Subject: [PATCH 36/75] move to new pipeline --- Build/debugpy-version.txt | 2 +- Build/nuget.config | 2 +- azure-pipelines-integration-tests-gate.yml | 74 ++++++++++++++++++++++ 3 files changed, 76 insertions(+), 2 deletions(-) create mode 100644 azure-pipelines-integration-tests-gate.yml diff --git a/Build/debugpy-version.txt b/Build/debugpy-version.txt index e06e7a26c8..bbaa9e1622 100644 --- a/Build/debugpy-version.txt +++ b/Build/debugpy-version.txt @@ -1 +1 @@ -1.8.17 \ No newline at end of file +1.8.18 \ No newline at end of file diff --git a/Build/nuget.config b/Build/nuget.config index 842230ada0..eb4f86f1f5 100644 --- a/Build/nuget.config +++ b/Build/nuget.config @@ -5,7 +5,7 @@ - + diff --git a/azure-pipelines-integration-tests-gate.yml b/azure-pipelines-integration-tests-gate.yml new file mode 100644 index 0000000000..4757a046e6 --- /dev/null +++ b/azure-pipelines-integration-tests-gate.yml @@ -0,0 +1,74 @@ +# Don't trigger ci or pr builds +trigger: none +pr: none + +# The following steps describe how to create a DartLab pipeline that installs Visual Studio using a bootstrapper generated by the MicroBuild Build VS Bootstrapper task +# in the component repo's MicroBuild: https://dev.azure.com/devdiv/DevDiv/_wiki/wikis/DevDiv.wiki/45681/Component-Repository +resources: + + pipelines: + + # All PTVS build artifacts come from this pipeline and are referenced like this: + # $(Pipeline.Workspace)\ComponentBuildUnderTest\\ + - pipeline: ComponentBuildUnderTest + project: DevDiv + source: Python\PTVS\PTVS-Build + branch: main # This is only used for manual/scheduled runs of this pipeline + trigger: + branches: + include: + - main + - release/* + + - pipeline: DartLab + project: DevDiv + source: DartLab + branch: main + + repositories: + + - repository: DartLabTemplates + type: git + name: DartLab.Templates + ref: refs/heads/main + +stages: + +- template: stages/cloudtest/visual-studio/single-runsettings.yml@DartLabTemplates + parameters: + displayName: Integration Tests + owner: ptvs + testMachineLab: DDRITs-PR + # This assumes the PTVS build has published a build artifact called "RunSettings" that contains the default.runsettings file + runSettingsURI: https://vsdrop.microsoft.com/file/v1/$(RunSettings.DropName);default.runsettings + visualStudioBootstrapperURI: $(VisualStudio.InstallationUnderTest.BootstrapperURL) + visualStudioSigning: Test + testMachineConfigurationJobVariables: + - name: VisualStudio.InstallationUnderTest.BootstrapperBranch + value: main + # These steps run on the machine that is creating the test machine configuration, which isn't the same + # as the machine running the actual tests + preTestMachineConfigurationSteps: + + - download: ComponentBuildUnderTest + artifact: MicroBuildOutputs + patterns: '**\BootstrapperInfo.json' + displayName: Download Bootstrapper Information + + - task: PowerShell@2 + displayName: Set 'VisualStudio.InstallationUnderTest.BootstrapperURL' + inputs: + filePath: $(DartLab.Path)\Scripts\VisualStudio\Bootstrapper\Get-BootstrapperURL.ps1 + arguments: -BootstrapperInfoJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\MicroBuildOutputs\BootstrapperInfo.json' -VSBranch '$(VisualStudio.InstallationUnderTest.BootstrapperBranch)' -OutVariableName 'VisualStudio.InstallationUnderTest.BootstrapperURL' + + - download: ComponentBuildUnderTest + artifact: PTVS-TestData + patterns: '**\VSTSDrop.json' + displayName: Download drop Information + + - template: \steps\powershell\execute-script.yml@DartLabTemplates + parameters: + displayName: Set 'RunSettings.DropName' + filePath: $(DartLab.Path)\Scripts\AzureDevOps\Artifacts\Drop\Get-DropName.ps1 + arguments: -VSTSDropJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\PTVS-TestData\VSTSDrop.json' -OutVariableName 'RunSettings.DropName' + \ No newline at end of file From c0ae837ac64fb862a384e029283a20ed10cc6bae Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 28 Jan 2026 17:05:52 -0800 Subject: [PATCH 37/75] rename pipeline --- ...on-tests-gate.yml => azure-pipelines-integration-testsgate.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename azure-pipelines-integration-tests-gate.yml => azure-pipelines-integration-testsgate.yml (100%) diff --git a/azure-pipelines-integration-tests-gate.yml b/azure-pipelines-integration-testsgate.yml similarity index 100% rename from azure-pipelines-integration-tests-gate.yml rename to azure-pipelines-integration-testsgate.yml From 88d6554313ed90c83bb97dabc2c03f898c3ca8e3 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 10:40:07 -0800 Subject: [PATCH 38/75] remove branch --- azure-pipelines-integration-testsgate.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index 4757a046e6..bbf2915141 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -13,7 +13,7 @@ resources: - pipeline: ComponentBuildUnderTest project: DevDiv source: Python\PTVS\PTVS-Build - branch: main # This is only used for manual/scheduled runs of this pipeline + trigger: branches: include: From d8cea901276fb57e2c96ce19428ec375470e8ef9 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 12:25:35 -0800 Subject: [PATCH 39/75] list files --- azure-pipelines-integration-testsgate.yml | 36 +++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index bbf2915141..40286592a2 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -66,6 +66,42 @@ stages: patterns: '**\VSTSDrop.json' displayName: Download drop Information + - task: PowerShell@2 + displayName: List downloaded files before setting 'RunSettings.DropName' + inputs: + targetType: inline + script: | + Write-Host "Pipeline.Workspace: $(Pipeline.Workspace)" + Write-Host "System.DefaultWorkingDirectory: $(System.DefaultWorkingDirectory)" + + $componentRoot = Join-Path "$(Pipeline.Workspace)" "ComponentBuildUnderTest" + $testDataRoot = Join-Path $componentRoot "PTVS-TestData" + + Write-Host "Listing: $componentRoot" + if (Test-Path -LiteralPath $componentRoot) { + Get-ChildItem -LiteralPath $componentRoot -Force | Select-Object Name, FullName, Mode, Length, LastWriteTime | Format-Table -AutoSize + } else { + Write-Warning "Path not found: $componentRoot" + } + + Write-Host "Listing (recursive): $testDataRoot" + if (Test-Path -LiteralPath $testDataRoot) { + Get-ChildItem -LiteralPath $testDataRoot -Recurse -Force | + Select-Object FullName, Length, LastWriteTime | + Sort-Object FullName | + Format-Table -AutoSize + + Write-Host "Searching for VSTSDrop.json under: $testDataRoot" + $matches = Get-ChildItem -LiteralPath $testDataRoot -Recurse -Force -File -Filter "VSTSDrop.json" -ErrorAction SilentlyContinue + if ($matches) { + $matches | Select-Object FullName, Length, LastWriteTime | Format-Table -AutoSize + } else { + Write-Warning "No VSTSDrop.json found under: $testDataRoot" + } + } else { + Write-Warning "Path not found: $testDataRoot" + } + - template: \steps\powershell\execute-script.yml@DartLabTemplates parameters: displayName: Set 'RunSettings.DropName' From 9ab88827dbecfdc76ca5f2d1906861c6e15f3f99 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 13:00:26 -0800 Subject: [PATCH 40/75] set buildNumber --- azure-pipelines.yml | 471 +++++++++++++++++++++----------------------- 1 file changed, 230 insertions(+), 241 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 539a8c776f..601fa23020 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -4,49 +4,48 @@ # The pipeline extends v1/1ES.Official.PipelineTemplate.yml@1ESPipelineTemplates from 1esPipelines repository defined in resources section. parameters: + - name: pylanceVersion + displayName: Pylance Version + type: string + default: latest + + - name: pylanceReleaseType + displayName: Pylance Release Type + type: string + default: stable + values: + - stable + - preview + + - name: debugpyVersion + displayName: Debugpy Version + type: string + default: latest -- name: pylanceVersion - displayName: Pylance Version - type: string - default: latest - -- name: pylanceReleaseType - displayName: Pylance Release Type - type: string - default: stable - values: - - stable - - preview - -- name: debugpyVersion - displayName: Debugpy Version - type: string - default: latest - -- name: PublishNugetPackageAsBuildArtifact - displayName: Publish Nuget Package As Build Artifact - type: boolean - default: false - -# This is the version that the PTVS package currently being built will have. -# If this value is set to 'currentBuildNumber' will default to $(Build.BuildNumber). -# But this parameter can be used to overwrite the version number if needed. -- name: ptvsPackageVersion - displayName: PTVS Package Version - type: string - default: currentBuildNumber - -- name: skipGlassCache - displayName: Skip Glass Cache - type: boolean - default: false - -- name: skipSigning - displayName: Skip Signing - type: boolean - default: false - -# build number format + - name: PublishNugetPackageAsBuildArtifact + displayName: Publish Nuget Package As Build Artifact + type: boolean + default: false + + # This is the version that the PTVS package currently being built will have. + # If this value is set to 'currentBuildNumber' will default to $(Build.BuildNumber). + # But this parameter can be used to overwrite the version number if needed. + - name: ptvsPackageVersion + displayName: PTVS Package Version + type: string + default: currentBuildNumber + + - name: skipGlassCache + displayName: Skip Glass Cache + type: boolean + default: false + + - name: skipSigning + displayName: Skip Signing + type: boolean + default: false + +# build number format name: $(date:yy)$(DayOfYear)$(rev:.r) # Trigger ci builds for commits into master and any release branches @@ -58,7 +57,7 @@ trigger: - release/* paths: exclude: - - 'azure-pipelines-*.yml' + - "azure-pipelines-*.yml" # Trigger pr builds for commits into master and any release branches # Ignore changes to other yml files, since they are for different pipelines @@ -70,19 +69,19 @@ pr: - release/* paths: exclude: - - 'azure-pipelines-*.yml' + - "azure-pipelines-*.yml" drafts: false # Trigger builds on a nightly schedule # Always run, even if there are no PTVS changes, because we want the latest changes from all dependencies # such as pylance, debugpy, and the latest VS int-preview bits pulled into our bootstrapper. schedules: -- cron: "0 8 * * *" - displayName: Nightly build - branches: - include: - - main - always: true + - cron: "0 8 * * *" + displayName: Nightly build + branches: + include: + - main + always: true # Build variables # None of these are settable at build queue time. To do that, remove the variable from this list, @@ -103,7 +102,7 @@ variables: - name: TrackFileAccess value: false - name: Packaging.EnableSBOMSigning - value: false # disabled for now because of known issue + value: false # disabled for now because of known issue - name: SkipGlassCache value: ${{ parameters.skipGlassCache }} - name: PublishNugetPackageAsBuildArtifact @@ -115,7 +114,7 @@ variables: value: preview ${{ else }}: value: ${{ parameters.pylanceReleaseType }} - + # If the vs package version is not specified, use the build number - name: ptvsPackageVersionVar ${{ if eq(parameters.ptvsPackageVersion, 'currentBuildNumber') }}: @@ -137,16 +136,16 @@ variables: # The ref of the repository is set to release tag which is intended to be used by most pipelines. resources: repositories: - - repository: 1ESPipelineTemplates - type: git - name: 1ESPipelineTemplates/1ESPipelineTemplates - ref: refs/tags/release + - repository: 1ESPipelineTemplates + type: git + name: 1ESPipelineTemplates/1ESPipelineTemplates + ref: refs/tags/release extends: template: v1/1ES.Official.PipelineTemplate.yml@1ESPipelineTemplates parameters: - # The pool includes the name of your 1ES hosted pool and a VM image in that pool. Also, use os to - # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. + # The pool includes the name of your 1ES hosted pool and a VM image in that pool. Also, use os to + # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. # Hence, this property must be specified for linux and macOS. pool: name: VSEngSS-MicroBuild2022-1ES @@ -154,187 +153,177 @@ extends: settings: skipBuildTagsForGitHubPullRequests: true stages: - - stage: build - displayName: Build - jobs: - - job: build - # Set pipeline timeout to 2 hours (120 minutes) - timeoutInMinutes: 120 + - stage: build displayName: Build - variables: - BootloaderDropName: 'Bootloader/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)' - # If the pipeline publishes artifacts, use `templateContext` to define the artifacts. - # This will enable 1ES PT to run SDL analysis tools on the artifacts and then upload them. - templateContext: - isProduction: false - # Disable code signing validation because we don't ship ANY of the artifacts that we publish. - # The only released artifacts are uploaded via the 1ES.MicroBuildVstsDrop@1 below. - sdl: - codeql: - # disable if not commit in main or release - ${{ if or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'], 'refs/heads/release/')) }}: - enabled: true - ${{ else }}: - enabled: false - codeSignValidation: - enabled: false - sbom: - enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output - outputs: - # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - # displayName: 'Upload MicroBuild to Artifact Services' - # sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output - # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - # dropMetadataContainerName: MicroBuildOutputs - # buildNumber: '$(BootloaderDropName)' - - output: pipelineArtifact - displayName: 📢 Publish MicroBuildOutputs - targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output - artifactName: MicroBuildOutputs - - output: pipelineArtifact - displayName: 'Publish build artifact: binaries' - targetPath: '$(Build.BinariesDirectory)/raw/binaries' - artifactName: Binaries - - output: pipelineArtifact - displayName: 'Publish build artifact: raw' - condition: failed() - targetPath: '$(Build.BinariesDirectory)\raw' - artifactName: raw - - output: pipelineArtifact - displayName: 'Publish build artifact: logs' - condition: succeededOrFailed() - targetPath: '$(Build.SourcesDirectory)\logs' - artifactName: Logs - - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: - - output: pipelineArtifact - displayName: 'Publish build artifact: BoM' - targetPath: '$(Build.BinariesDirectory)\layout' - artifactName: SBOM - - ${{ if or(notin(variables['Build.Reason'], 'PullRequest'), eq(variables['PublishNugetPackageAsBuildArtifact'], true)) }}: - - output: pipelineArtifact - displayName: 'Publish build artifact: NuGet Package' - targetPath: '$(Build.ArtifactStagingDirectory)\pkg' - artifactName: pkg - - steps: - - # check out code clean from source control - - checkout: self - clean: true - fetchDepth: 1 - persistCredentials: true - - # Non-PR steps - - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: - - # add VSTarget build tag - - powershell: 'Write-Host "##vso[build.addbuildtag]$env:VSTarget"' - displayName: 'Add vstarget build tag' - - # install microbuild plugins used for swixproj/vsmanproj, signing, and localization - - template: /Build/templates/install_microbuild_plugins.yml@self - - # Restore packages and install dependencies (pylance, debugpy) - - template: /Build/templates/restore_packages.yml@self - parameters: - pylanceVersion: ${{ parameters.pylanceVersion }} - pylanceReleaseType: ${{ variables.pylanceReleaseTypeVar }} - debugpyVersion: ${{ parameters.debugpyVersion }} - - # Build and publish logs - - template: /Build/templates/build.yml@self - parameters: - ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} - skipSigning: ${{ variables.skipSigningVar }} - - # Non-PR steps - - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: - - # Create VS bootstrapper for testing - - template: Build/templates/create_vs_bootstrapper.yml@self - - # Upload vsts drop used by Visual Studio insertions - # For more info, see https://eng.ms/docs/cloud-ai-platform/devdiv/one-engineering-system-1es/1es-docs/1es-pipeline-templates/features/outputs/microbuild-vsts-drop - - task: 1ES.MicroBuildVstsDrop@1 - displayName: 'Upload vsts drop' - inputs: - dropFolder: '$(Build.StagingDirectory)\release' - dropServiceUri: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection' - vsDropServiceUri: 'https://vsdrop.corp.microsoft.com/file/v1' - accessToken: '$(System.AccessToken)' - dropRetentionDays: 183 - - # publish symbols - - template: /Build/templates/publish_symbols.yml@self - - # Build and publish nuget package used by VS - - template: /Build/templates/build_nuget_package.yml@self - parameters: - ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} - - # MicroBuild cleanup - - task: MicroBuildCleanup@1 - displayName: 'Execute cleanup tasks' - condition: succeededOrFailed() - - # Separate job for TestData generation - runs in parallel with build job - - job: testdata - displayName: Publish TestData - variables: - TestDataDropName: 'TestData/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)' - templateContext: - isProduction: false - sdl: - codeSignValidation: - enabled: false - sbom: - enabled: false - outputs: - - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - displayName: 'Upload Test Data to Artifact Services' - sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder - dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - # buildNumber: '$(TestDataDropName)' - dropMetadataContainerName: PTVS-TestData - - output: pipelineArtifact - displayName: 'Publish build artifact: TestData' - targetPath: '$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip' - artifactName: 'TestData' - - output: pipelineArtifact - displayName: 'Publish build artifact: RunSettings' - targetPath: '$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings' - artifactName: 'RunSettings' - - steps: - # check out code clean from source control - - checkout: self - clean: true - fetchDepth: 1 - persistCredentials: true - - # Publish test data - - template: /Build/templates/publish_test_data.yml@self - - # Copy runsettings to TestDataFolder for azure_pipelines_integration_tests.yml pipeline - - task: CopyFiles@2 - displayName: 'Copy runsettings to TestDataFolder' - inputs: - SourceFolder: '$(Build.SourcesDirectory)/Python/Tests/TestData' - Contents: 'default.runsettings' - TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' - - # Run tests on mixed mode debugger but only for PR builds - # - ${{ if or(eq(variables['Build.Reason'], 'PullRequest'), eq(variables['SkipGlassCache'], true)) }}: - # - job: test - # displayName: Test - # steps: - # - template: /Build/templates/run_tests.yml@self - # parameters: - # skipGlassCache: ${{ parameters.skipGlassCache }} - - - - - - - + jobs: + - job: build + # Set pipeline timeout to 2 hours (120 minutes) + timeoutInMinutes: 120 + displayName: Build + variables: + BootloaderDropName: "Bootloader/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)" + # If the pipeline publishes artifacts, use `templateContext` to define the artifacts. + # This will enable 1ES PT to run SDL analysis tools on the artifacts and then upload them. + templateContext: + isProduction: false + # Disable code signing validation because we don't ship ANY of the artifacts that we publish. + # The only released artifacts are uploaded via the 1ES.MicroBuildVstsDrop@1 below. + sdl: + codeql: + # disable if not commit in main or release + ${{ if or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'], 'refs/heads/release/')) }}: + enabled: true + ${{ else }}: + enabled: false + codeSignValidation: + enabled: false + sbom: + enabled: false # Disable global SBOM generation; we'll enable selectively per artifact output + outputs: + # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + # displayName: 'Upload MicroBuild to Artifact Services' + # sourcePath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + # dropMetadataContainerName: MicroBuildOutputs + # buildNumber: '$(BootloaderDropName)' + - output: pipelineArtifact + displayName: 📢 Publish MicroBuildOutputs + targetPath: $(Build.ArtifactStagingDirectory)\MicroBuild\Output + artifactName: MicroBuildOutputs + - output: pipelineArtifact + displayName: "Publish build artifact: binaries" + targetPath: "$(Build.BinariesDirectory)/raw/binaries" + artifactName: Binaries + - output: pipelineArtifact + displayName: "Publish build artifact: raw" + condition: failed() + targetPath: '$(Build.BinariesDirectory)\raw' + artifactName: raw + - output: pipelineArtifact + displayName: "Publish build artifact: logs" + condition: succeededOrFailed() + targetPath: '$(Build.SourcesDirectory)\logs' + artifactName: Logs + - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: + - output: pipelineArtifact + displayName: "Publish build artifact: BoM" + targetPath: '$(Build.BinariesDirectory)\layout' + artifactName: SBOM + - ${{ if or(notin(variables['Build.Reason'], 'PullRequest'), eq(variables['PublishNugetPackageAsBuildArtifact'], true)) }}: + - output: pipelineArtifact + displayName: "Publish build artifact: NuGet Package" + targetPath: '$(Build.ArtifactStagingDirectory)\pkg' + artifactName: pkg + + steps: + # check out code clean from source control + - checkout: self + clean: true + fetchDepth: 1 + persistCredentials: true + + # Non-PR steps + - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: + # add VSTarget build tag + - powershell: 'Write-Host "##vso[build.addbuildtag]$env:VSTarget"' + displayName: "Add vstarget build tag" + + # install microbuild plugins used for swixproj/vsmanproj, signing, and localization + - template: /Build/templates/install_microbuild_plugins.yml@self + + # Restore packages and install dependencies (pylance, debugpy) + - template: /Build/templates/restore_packages.yml@self + parameters: + pylanceVersion: ${{ parameters.pylanceVersion }} + pylanceReleaseType: ${{ variables.pylanceReleaseTypeVar }} + debugpyVersion: ${{ parameters.debugpyVersion }} + + # Build and publish logs + - template: /Build/templates/build.yml@self + parameters: + ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} + skipSigning: ${{ variables.skipSigningVar }} + + # Non-PR steps + - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: + # Create VS bootstrapper for testing + - template: Build/templates/create_vs_bootstrapper.yml@self + + # Upload vsts drop used by Visual Studio insertions + # For more info, see https://eng.ms/docs/cloud-ai-platform/devdiv/one-engineering-system-1es/1es-docs/1es-pipeline-templates/features/outputs/microbuild-vsts-drop + - task: 1ES.MicroBuildVstsDrop@1 + displayName: "Upload vsts drop" + inputs: + dropFolder: '$(Build.StagingDirectory)\release' + dropServiceUri: "https://devdiv.artifacts.visualstudio.com/DefaultCollection" + vsDropServiceUri: "https://vsdrop.corp.microsoft.com/file/v1" + accessToken: "$(System.AccessToken)" + dropRetentionDays: 183 + + # publish symbols + - template: /Build/templates/publish_symbols.yml@self + + # Build and publish nuget package used by VS + - template: /Build/templates/build_nuget_package.yml@self + parameters: + ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} + + # MicroBuild cleanup + - task: MicroBuildCleanup@1 + displayName: "Execute cleanup tasks" + condition: succeededOrFailed() + + # Separate job for TestData generation - runs in parallel with build job + - job: testdata + displayName: Publish TestData + variables: + TestDataDropName: "TestData/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)" + templateContext: + isProduction: false + sdl: + codeSignValidation: + enabled: false + sbom: + enabled: false + outputs: + - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + displayName: "Upload Test Data to Artifact Services" + sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder + dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + buildNumber: "$(TestDataDropName)" + dropMetadataContainerName: PTVS-TestData + - output: pipelineArtifact + displayName: "Publish build artifact: TestData" + targetPath: "$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip" + artifactName: "TestData" + - output: pipelineArtifact + displayName: "Publish build artifact: RunSettings" + targetPath: "$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings" + artifactName: "RunSettings" + + steps: + # check out code clean from source control + - checkout: self + clean: true + fetchDepth: 1 + persistCredentials: true + + # Publish test data + - template: /Build/templates/publish_test_data.yml@self + + # Copy runsettings to TestDataFolder for azure_pipelines_integration_tests.yml pipeline + - task: CopyFiles@2 + displayName: "Copy runsettings to TestDataFolder" + inputs: + SourceFolder: "$(Build.SourcesDirectory)/Python/Tests/TestData" + Contents: "default.runsettings" + TargetFolder: "$(Build.ArtifactStagingDirectory)/TestDataFolder" + + # Run tests on mixed mode debugger but only for PR builds + # - ${{ if or(eq(variables['Build.Reason'], 'PullRequest'), eq(variables['SkipGlassCache'], true)) }}: + # - job: test + # displayName: Test + # steps: + # - template: /Build/templates/run_tests.yml@self + # parameters: + # skipGlassCache: ${{ parameters.skipGlassCache }} From 28aecfa9c9deb3d66c346b14b957c0985bbb99d0 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 13:29:12 -0800 Subject: [PATCH 41/75] try pipelineArtifact for PTVS-TestData --- azure-pipelines.yml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 601fa23020..77598532a6 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -286,12 +286,16 @@ extends: sbom: enabled: false outputs: - - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - displayName: "Upload Test Data to Artifact Services" - sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder - dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - buildNumber: "$(TestDataDropName)" - dropMetadataContainerName: PTVS-TestData + - output: pipelineArtifact + displayName: 📢 Publish PTVS-TestData + targetPath: $(Build.ArtifactStagingDirectory)\PTVS-TestData\ + artifactName: PTVS-TestData + # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + # displayName: "Upload Test Data to Artifact Services" + # sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder + # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + # buildNumber: "$(TestDataDropName)" + # dropMetadataContainerName: PTVS-TestData - output: pipelineArtifact displayName: "Publish build artifact: TestData" targetPath: "$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip" From d0bc838de09dc759bc82f3dc46bf84f53bb9a69f Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 14:06:01 -0800 Subject: [PATCH 42/75] add back msft_consumption --- Build/nuget.config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Build/nuget.config b/Build/nuget.config index eb4f86f1f5..848d116912 100644 --- a/Build/nuget.config +++ b/Build/nuget.config @@ -5,7 +5,7 @@ - + From 9aa441c8a5bcf7de9ace8fc186433875d611979d Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 16:31:12 -0800 Subject: [PATCH 43/75] only one feed. remove python --- Build/18.0/packages.config | 1 - Build/nuget.config | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Build/18.0/packages.config b/Build/18.0/packages.config index ce411012c0..210c9385e2 100644 --- a/Build/18.0/packages.config +++ b/Build/18.0/packages.config @@ -1,7 +1,6 @@ - diff --git a/Build/nuget.config b/Build/nuget.config index 848d116912..58dccd482b 100644 --- a/Build/nuget.config +++ b/Build/nuget.config @@ -3,9 +3,9 @@ - + - + From 3548f82aa86d9fbad8970b6d19968e8c00c2dcea Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 30 Jan 2026 16:44:04 -0800 Subject: [PATCH 44/75] change build pool --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 77598532a6..3f5dd84835 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -148,7 +148,7 @@ extends: # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. # Hence, this property must be specified for linux and macOS. pool: - name: VSEngSS-MicroBuild2022-1ES + name: AzurePipelines-EO os: windows settings: skipBuildTagsForGitHubPullRequests: true From 11ce9af7502fb18b999ab8df8fb6b5a5cae07587 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Sat, 31 Jan 2026 13:31:07 -0800 Subject: [PATCH 45/75] try different pool --- azure-pipelines.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 3f5dd84835..548cce86c3 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -149,6 +149,7 @@ extends: # Hence, this property must be specified for linux and macOS. pool: name: AzurePipelines-EO + image: 1ESPT-Windows2022 os: windows settings: skipBuildTagsForGitHubPullRequests: true From b5bdf1595d2eb6330bb06e7efe5fbc77c55131f9 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Sat, 31 Jan 2026 13:48:42 -0800 Subject: [PATCH 46/75] add back both feeds --- Build/nuget.config | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Build/nuget.config b/Build/nuget.config index 58dccd482b..3a04bda1db 100644 --- a/Build/nuget.config +++ b/Build/nuget.config @@ -5,8 +5,8 @@ - - + + From 1a1ef0e017d0989dc37b5a0b1e8498104ba4d8f1 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Sat, 31 Jan 2026 14:17:15 -0800 Subject: [PATCH 47/75] go back to msft_consumption --- Build/nuget.config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Build/nuget.config b/Build/nuget.config index 3a04bda1db..b441bb20ef 100644 --- a/Build/nuget.config +++ b/Build/nuget.config @@ -6,7 +6,7 @@ - + From 4a9108e82cc4bc83ea0cce055893690835b61f83 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Sat, 31 Jan 2026 22:46:12 -0800 Subject: [PATCH 48/75] try to fix PTVS-TestData --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 548cce86c3..02e4376422 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -289,7 +289,7 @@ extends: outputs: - output: pipelineArtifact displayName: 📢 Publish PTVS-TestData - targetPath: $(Build.ArtifactStagingDirectory)\PTVS-TestData\ + targetPath: $(Build.ArtifactStagingDirectory)/TestDataFolder/ artifactName: PTVS-TestData # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline # displayName: "Upload Test Data to Artifact Services" From d061a2d79564e07a08cd8157f2aa2f0e266f6057 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 2 Feb 2026 13:48:00 -0800 Subject: [PATCH 49/75] try to push stuff to artiffact drop --- azure-pipelines.yml | 59 +++++++++++++++++++++++---------------------- 1 file changed, 30 insertions(+), 29 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 02e4376422..3500947a5a 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -246,28 +246,28 @@ extends: skipSigning: ${{ variables.skipSigningVar }} # Non-PR steps - - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: - # Create VS bootstrapper for testing - - template: Build/templates/create_vs_bootstrapper.yml@self - - # Upload vsts drop used by Visual Studio insertions - # For more info, see https://eng.ms/docs/cloud-ai-platform/devdiv/one-engineering-system-1es/1es-docs/1es-pipeline-templates/features/outputs/microbuild-vsts-drop - - task: 1ES.MicroBuildVstsDrop@1 - displayName: "Upload vsts drop" - inputs: - dropFolder: '$(Build.StagingDirectory)\release' - dropServiceUri: "https://devdiv.artifacts.visualstudio.com/DefaultCollection" - vsDropServiceUri: "https://vsdrop.corp.microsoft.com/file/v1" - accessToken: "$(System.AccessToken)" - dropRetentionDays: 183 - - # publish symbols - - template: /Build/templates/publish_symbols.yml@self - - # Build and publish nuget package used by VS - - template: /Build/templates/build_nuget_package.yml@self - parameters: - ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} + # - ${{ if notin(variables['Build.Reason'], 'PullRequest') }}: + # Create VS bootstrapper for testing + - template: Build/templates/create_vs_bootstrapper.yml@self + + # Upload vsts drop used by Visual Studio insertions + # For more info, see https://eng.ms/docs/cloud-ai-platform/devdiv/one-engineering-system-1es/1es-docs/1es-pipeline-templates/features/outputs/microbuild-vsts-drop + - task: 1ES.MicroBuildVstsDrop@1 + displayName: "Upload vsts drop" + inputs: + dropFolder: '$(Build.StagingDirectory)\release' + dropServiceUri: "https://devdiv.artifacts.visualstudio.com/DefaultCollection" + vsDropServiceUri: "https://vsdrop.corp.microsoft.com/file/v1" + accessToken: "$(System.AccessToken)" + dropRetentionDays: 183 + + # publish symbols + - template: /Build/templates/publish_symbols.yml@self + + # Build and publish nuget package used by VS + - template: /Build/templates/build_nuget_package.yml@self + parameters: + ptvsPackageVersion: ${{ variables.ptvsPackageVersionVar }} # MicroBuild cleanup - task: MicroBuildCleanup@1 @@ -278,7 +278,8 @@ extends: - job: testdata displayName: Publish TestData variables: - TestDataDropName: "TestData/$(System.TeamProject)/$(Build.BuildNumber)/$(Build.BuildId)" + TestDataDropName: "DevDiv/PTVS/Tests/$(Build.BuildNumber)/$(Build.BuildId)" + TestStoreDropName: "$(TestDataDropName)" templateContext: isProduction: false sdl: @@ -291,12 +292,12 @@ extends: displayName: 📢 Publish PTVS-TestData targetPath: $(Build.ArtifactStagingDirectory)/TestDataFolder/ artifactName: PTVS-TestData - # - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline - # displayName: "Upload Test Data to Artifact Services" - # sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder - # dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ - # buildNumber: "$(TestDataDropName)" - # dropMetadataContainerName: PTVS-TestData + - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline + displayName: "Upload Test Data to Artifact Services" + sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder + dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ + buildNumber: "$(TestDataDropName)" + dropMetadataContainerName: PTVS-TestData - output: pipelineArtifact displayName: "Publish build artifact: TestData" targetPath: "$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip" From 64aa50a7a86fafd1208899e4c5dd30141578079e Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 2 Feb 2026 15:45:26 -0800 Subject: [PATCH 50/75] change pool --- azure-pipelines.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 3500947a5a..f603489249 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -148,8 +148,7 @@ extends: # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. # Hence, this property must be specified for linux and macOS. pool: - name: AzurePipelines-EO - image: 1ESPT-Windows2022 + name: VSEngSS-MicroBuild2022Preview-1ES os: windows settings: skipBuildTagsForGitHubPullRequests: true From 620360ad8346b46337c2c312274f3bc663cbbbf4 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 2 Feb 2026 16:07:19 -0800 Subject: [PATCH 51/75] move back to VSEngSS-MicroBuild2022-1ES --- azure-pipelines.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index f603489249..af6e46e071 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -148,8 +148,7 @@ extends: # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. # Hence, this property must be specified for linux and macOS. pool: - name: VSEngSS-MicroBuild2022Preview-1ES - os: windows + name: VSEngSS-MicroBuild2022-1ES settings: skipBuildTagsForGitHubPullRequests: true stages: From e300d8b00994c53e63aa6b93e4dbf0d5228872cf Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 2 Feb 2026 16:13:59 -0800 Subject: [PATCH 52/75] try large pool --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index af6e46e071..6fad8316d8 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -148,7 +148,7 @@ extends: # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. # Hence, this property must be specified for linux and macOS. pool: - name: VSEngSS-MicroBuild2022-1ES + name: VSEngSS-MicroBuild2022-large-1ES settings: skipBuildTagsForGitHubPullRequests: true stages: From b378f122bd6a382d18366015e3c505bbcd8ab166 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 2 Feb 2026 16:20:26 -0800 Subject: [PATCH 53/75] change pool AzurePipelines-EO --- azure-pipelines.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 6fad8316d8..259eb20485 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -148,7 +148,8 @@ extends: # specify the image type. Here are the allowed values: windows, linux, or macOS. The default value is windows. # Hence, this property must be specified for linux and macOS. pool: - name: VSEngSS-MicroBuild2022-large-1ES + name: AzurePipelines-EO + image: 1ESPT-Windows2022 settings: skipBuildTagsForGitHubPullRequests: true stages: From 949dd250f8e8834f04dc147401063f8a5dfcb950 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 2 Feb 2026 16:35:29 -0800 Subject: [PATCH 54/75] skip signing --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 259eb20485..b173d165ac 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -43,7 +43,7 @@ parameters: - name: skipSigning displayName: Skip Signing type: boolean - default: false + default: true # build number format name: $(date:yy)$(DayOfYear)$(rev:.r) From 726558a34c0c4bbcd763b4789fe56d314f3d07d3 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 09:50:03 -0800 Subject: [PATCH 55/75] test folder testing --- Build/templates/publish_test_data.yml | 33 +++++++++++++++++++++++++++ azure-pipelines.yml | 2 +- 2 files changed, 34 insertions(+), 1 deletion(-) diff --git a/Build/templates/publish_test_data.yml b/Build/templates/publish_test_data.yml index cdd38b4847..c2d802f3ae 100644 --- a/Build/templates/publish_test_data.yml +++ b/Build/templates/publish_test_data.yml @@ -1,5 +1,31 @@ steps: + # Generate a runsettings file that points at the correct Test Store drop. + - task: MSBuild@1 + displayName: 'Build PTVS.runsettingsproj' + inputs: + solution: '$(Build.SourcesDirectory)/Python/Tests/PTVS.runsettingsproj' + msbuildArguments: > + /p:PackagesPath=$(Build.SourcesDirectory)\packages + /p:TestStoreDropName=$(TestStoreDropName) + + - task: PowerShell@2 + displayName: 'Update default.runsettings from generated DDRITs.runsettings' + inputs: + targetType: 'inline' + script: | + $ErrorActionPreference = 'Stop' + + $source = "$(Build.SourcesDirectory)\Python\Tests\bin\RunSettings\DDRITs.runsettings" + $dest = "$(Build.SourcesDirectory)\Python\Tests\TestData\DDRITs.runsettings" + + if (-not (Test-Path -LiteralPath $source)) { + throw "Expected generated runsettings file not found: $source" + } + + Copy-Item -LiteralPath $source -Destination $dest -Force + + # Compress just the test data # Used in this release task to run tests: https://devdiv.visualstudio.com/DevDiv/_taskgroup/a7b18468-aab5-4be7-b718-02f85b0828c4 - task: ArchiveFiles@2 @@ -20,6 +46,13 @@ steps: Contents: 'TestData.zip' TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' + - task: CopyFiles@2 + displayName: 'Copy DDRITs.runsettings to subfolder' + inputs: + SourceFolder: '$(Build.SourcesDirectory)/Python/Tests/TestData' + Contents: 'DDRITs.runsettings' + TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' + # The Task 'PublishBuildArtifacts@1' has been converted to an output named 'Publish build artifact: TestData' in the templateContext section. # The Task 'PublishBuildArtifacts@1' has been converted to an output named 'Publish build artifact: RunSettings' in the templateContext section. \ No newline at end of file diff --git a/azure-pipelines.yml b/azure-pipelines.yml index b173d165ac..f86db7e5f6 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -290,7 +290,7 @@ extends: - output: pipelineArtifact displayName: 📢 Publish PTVS-TestData targetPath: $(Build.ArtifactStagingDirectory)/TestDataFolder/ - artifactName: PTVS-TestData + artifactName: TestDataFolder - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline displayName: "Upload Test Data to Artifact Services" sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder From 516348628508659bf6f36fbf6d04065d0c9c8296 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 11:42:59 -0800 Subject: [PATCH 56/75] add nuget config and setup for tests runtimesettings --- Build/nuget.testdata.config | 24 ++++++++++++++++++++++++ Build/templates/publish_test_data.yml | 12 ++++++++++++ Build/testdata.packages.config | 4 ++++ 3 files changed, 40 insertions(+) create mode 100644 Build/nuget.testdata.config create mode 100644 Build/testdata.packages.config diff --git a/Build/nuget.testdata.config b/Build/nuget.testdata.config new file mode 100644 index 0000000000..6ffb9ce36d --- /dev/null +++ b/Build/nuget.testdata.config @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + Microsoft;xunit;manuel.roemer;sharwell;jamesnk;aarnott;MarcoRossignoli;Thecentury;AndreyAkinshin;0xd4d;ericnewton76;jkeech;steve.dower + + + + + + + + diff --git a/Build/templates/publish_test_data.yml b/Build/templates/publish_test_data.yml index c2d802f3ae..2e432b8a13 100644 --- a/Build/templates/publish_test_data.yml +++ b/Build/templates/publish_test_data.yml @@ -1,5 +1,17 @@ steps: + - task: NuGetToolInstaller@1 + displayName: Install NuGet + + - task: NuGetCommand@2 + displayName: Restore runsettings build tasks + inputs: + command: restore + feedsToUse: config + restoreSolution: '$(Build.SourcesDirectory)/Build/testdata.packages.config' + restoreDirectory: '$(Build.SourcesDirectory)/packages' + nugetConfigPath: '$(Build.SourcesDirectory)/Build/nuget.testdata.config' + # Generate a runsettings file that points at the correct Test Store drop. - task: MSBuild@1 displayName: 'Build PTVS.runsettingsproj' diff --git a/Build/testdata.packages.config b/Build/testdata.packages.config new file mode 100644 index 0000000000..00494d7e05 --- /dev/null +++ b/Build/testdata.packages.config @@ -0,0 +1,4 @@ + + + + From e984560ea956ed0e92738e27c0f4c3b4eb70c4f2 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 11:52:15 -0800 Subject: [PATCH 57/75] rename nuget config for testdata --- Build/{testdata.packages.config => packages.testdata.config} | 0 Build/templates/publish_test_data.yml | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename Build/{testdata.packages.config => packages.testdata.config} (100%) diff --git a/Build/testdata.packages.config b/Build/packages.testdata.config similarity index 100% rename from Build/testdata.packages.config rename to Build/packages.testdata.config diff --git a/Build/templates/publish_test_data.yml b/Build/templates/publish_test_data.yml index 2e432b8a13..1d1e6d067a 100644 --- a/Build/templates/publish_test_data.yml +++ b/Build/templates/publish_test_data.yml @@ -8,7 +8,7 @@ steps: inputs: command: restore feedsToUse: config - restoreSolution: '$(Build.SourcesDirectory)/Build/testdata.packages.config' + restoreSolution: '$(Build.SourcesDirectory)/Build/packages.testdata.config' restoreDirectory: '$(Build.SourcesDirectory)/packages' nugetConfigPath: '$(Build.SourcesDirectory)/Build/nuget.testdata.config' From 5d48960c64d659344ba3236a4af63a5c0a5bff60 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 13:50:39 -0800 Subject: [PATCH 58/75] try to download all --- azure-pipelines-integration-testsgate.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index 40286592a2..0e4efa9657 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -63,7 +63,7 @@ stages: - download: ComponentBuildUnderTest artifact: PTVS-TestData - patterns: '**\VSTSDrop.json' + patterns: '**\*' displayName: Download drop Information - task: PowerShell@2 From 9757a0632206cabf6f85952c539c78e421fac081 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 13:50:58 -0800 Subject: [PATCH 59/75] remove runtimesettings --- azure-pipelines.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index f86db7e5f6..36accd5e58 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -301,10 +301,10 @@ extends: displayName: "Publish build artifact: TestData" targetPath: "$(Build.ArtifactStagingDirectory)/TestDataFolder/TestData.zip" artifactName: "TestData" - - output: pipelineArtifact - displayName: "Publish build artifact: RunSettings" - targetPath: "$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings" - artifactName: "RunSettings" + # - output: pipelineArtifact + # displayName: "Publish build artifact: RunSettings" + # targetPath: "$(Build.SourcesDirectory)/Python/Tests/TestData/default.runsettings" + # artifactName: "RunSettings" steps: # check out code clean from source control @@ -317,12 +317,12 @@ extends: - template: /Build/templates/publish_test_data.yml@self # Copy runsettings to TestDataFolder for azure_pipelines_integration_tests.yml pipeline - - task: CopyFiles@2 - displayName: "Copy runsettings to TestDataFolder" - inputs: - SourceFolder: "$(Build.SourcesDirectory)/Python/Tests/TestData" - Contents: "default.runsettings" - TargetFolder: "$(Build.ArtifactStagingDirectory)/TestDataFolder" + # - task: CopyFiles@2 + # displayName: "Copy runsettings to TestDataFolder" + # inputs: + # SourceFolder: "$(Build.SourcesDirectory)/Python/Tests/TestData" + # Contents: "DDRITs.runsettings" + # TargetFolder: "$(Build.ArtifactStagingDirectory)/TestDataFolder" # Run tests on mixed mode debugger but only for PR builds # - ${{ if or(eq(variables['Build.Reason'], 'PullRequest'), eq(variables['SkipGlassCache'], true)) }}: From 267baf5b23a454a39e9ac0b2a8f21bf39ac8c986 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 15:18:42 -0800 Subject: [PATCH 60/75] add a slash --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 36accd5e58..bcc0617b50 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -293,7 +293,7 @@ extends: artifactName: TestDataFolder - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline displayName: "Upload Test Data to Artifact Services" - sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder + sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder/ dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ buildNumber: "$(TestDataDropName)" dropMetadataContainerName: PTVS-TestData From 187528e9f2d196099c22db6640ab889ea4a777b0 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 15:19:38 -0800 Subject: [PATCH 61/75] revert --- azure-pipelines.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index bcc0617b50..36accd5e58 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -293,7 +293,7 @@ extends: artifactName: TestDataFolder - output: artifactsDrop # upload to artifact drop service for azure_pipelines_integration_tests.yml pipeline displayName: "Upload Test Data to Artifact Services" - sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder/ + sourcePath: $(Build.ArtifactStagingDirectory)/TestDataFolder dropServiceURI: https://devdiv.artifacts.visualstudio.com/DefaultCollection/ buildNumber: "$(TestDataDropName)" dropMetadataContainerName: PTVS-TestData From 82a74a0badb4044840e1f1617123dd11eb798cc4 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 19:03:16 -0800 Subject: [PATCH 62/75] try downloading more folds and list more files --- azure-pipelines-integration-testsgate.yml | 69 ++++++++++++++++++----- 1 file changed, 56 insertions(+), 13 deletions(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index 0e4efa9657..692cb9675b 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -66,6 +66,11 @@ stages: patterns: '**\*' displayName: Download drop Information + - download: ComponentBuildUnderTest + artifact: TestDataFolder + patterns: '**\*' + displayName: Download TestDataFolder Information + - task: PowerShell@2 displayName: List downloaded files before setting 'RunSettings.DropName' inputs: @@ -75,26 +80,64 @@ stages: Write-Host "System.DefaultWorkingDirectory: $(System.DefaultWorkingDirectory)" $componentRoot = Join-Path "$(Pipeline.Workspace)" "ComponentBuildUnderTest" - $testDataRoot = Join-Path $componentRoot "PTVS-TestData" - Write-Host "Listing: $componentRoot" - if (Test-Path -LiteralPath $componentRoot) { - Get-ChildItem -LiteralPath $componentRoot -Force | Select-Object Name, FullName, Mode, Length, LastWriteTime | Format-Table -AutoSize - } else { - Write-Warning "Path not found: $componentRoot" - } + function Write-RecursiveListing { + param( + [Parameter(Mandatory = $true)][string]$RootPath, + [Parameter(Mandatory = $true)][string]$Title + ) - Write-Host "Listing (recursive): $testDataRoot" - if (Test-Path -LiteralPath $testDataRoot) { - Get-ChildItem -LiteralPath $testDataRoot -Recurse -Force | - Select-Object FullName, Length, LastWriteTime | + Write-Host "" + Write-Host "==== $Title ====" + Write-Host "Root: $RootPath" + + if (-not (Test-Path -LiteralPath $RootPath)) { + Write-Warning "Path not found: $RootPath" + return + } + + Write-Host "Top-level entries:" + Get-ChildItem -LiteralPath $RootPath -Force | + Select-Object Name, FullName, Mode, Length, LastWriteTime | Sort-Object FullName | Format-Table -AutoSize - Write-Host "Searching for VSTSDrop.json under: $testDataRoot" + Write-Host "" + Write-Host "All files (recursive):" + $allFiles = Get-ChildItem -LiteralPath $RootPath -Recurse -Force -File -ErrorAction SilentlyContinue + if ($allFiles) { + $allFiles | + Select-Object FullName, Length, LastWriteTime | + Sort-Object FullName | + Format-Table -AutoSize + Write-Host "Total files: $($allFiles.Count)" + } else { + Write-Warning "No files found under: $RootPath" + } + + Write-Host "" + Write-Host "All directories (recursive):" + $allDirs = Get-ChildItem -LiteralPath $RootPath -Recurse -Force -Directory -ErrorAction SilentlyContinue + if ($allDirs) { + $allDirs | + Select-Object FullName, LastWriteTime | + Sort-Object FullName | + Format-Table -AutoSize + Write-Host "Total directories: $($allDirs.Count)" + } else { + Write-Warning "No directories found under: $RootPath" + } + } + + Write-RecursiveListing -RootPath $componentRoot -Title "Downloaded artifacts under ComponentBuildUnderTest" + + $testDataRoot = Join-Path $componentRoot "PTVS-TestData" + Write-Host "" + Write-Host "Searching for VSTSDrop.json under: $testDataRoot" + if (Test-Path -LiteralPath $testDataRoot) { $matches = Get-ChildItem -LiteralPath $testDataRoot -Recurse -Force -File -Filter "VSTSDrop.json" -ErrorAction SilentlyContinue if ($matches) { - $matches | Select-Object FullName, Length, LastWriteTime | Format-Table -AutoSize + $matches | Select-Object FullName, Length, LastWriteTime | Sort-Object FullName | Format-Table -AutoSize } else { Write-Warning "No VSTSDrop.json found under: $testDataRoot" } From 4bad6b5ba2fed991915e487478ccd25257646a1d Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 19:10:05 -0800 Subject: [PATCH 63/75] use DDRts --- azure-pipelines-integration-testsgate.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index 692cb9675b..a82f22c711 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -149,5 +149,5 @@ stages: parameters: displayName: Set 'RunSettings.DropName' filePath: $(DartLab.Path)\Scripts\AzureDevOps\Artifacts\Drop\Get-DropName.ps1 - arguments: -VSTSDropJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\PTVS-TestData\VSTSDrop.json' -OutVariableName 'RunSettings.DropName' + arguments: -VSTSDropJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\PTVS-TestData\VSTSDrop.json' -OutVariableName '$(Pipeline.Workspace)\ComponentBuildUnderTest\TestDataFolder\DDRITs.runsettings' \ No newline at end of file From 11264343f5024610e72da111c5393754621d334a Mon Sep 17 00:00:00 2001 From: bschnurr Date: Tue, 3 Feb 2026 19:22:26 -0800 Subject: [PATCH 64/75] $(Pipeline.Workspace)\ComponentBuildUnderTest\PTVS-TestData\VSTSDrop.json --- azure-pipelines-integration-testsgate.yml | 38 ++++++++++++++++++----- 1 file changed, 31 insertions(+), 7 deletions(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index a82f22c711..d6a124663e 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -131,23 +131,47 @@ stages: Write-RecursiveListing -RootPath $componentRoot -Title "Downloaded artifacts under ComponentBuildUnderTest" - $testDataRoot = Join-Path $componentRoot "PTVS-TestData" Write-Host "" - Write-Host "Searching for VSTSDrop.json under: $testDataRoot" - if (Test-Path -LiteralPath $testDataRoot) { - $matches = Get-ChildItem -LiteralPath $testDataRoot -Recurse -Force -File -Filter "VSTSDrop.json" -ErrorAction SilentlyContinue + Write-Host "Searching for VSTSDrop.json under: $componentRoot" + if (Test-Path -LiteralPath $componentRoot) { + $matches = Get-ChildItem -LiteralPath $componentRoot -Recurse -Force -File -Filter "VSTSDrop.json" -ErrorAction SilentlyContinue if ($matches) { $matches | Select-Object FullName, Length, LastWriteTime | Sort-Object FullName | Format-Table -AutoSize } else { - Write-Warning "No VSTSDrop.json found under: $testDataRoot" + Write-Warning "No VSTSDrop.json found under: $componentRoot" } } else { - Write-Warning "Path not found: $testDataRoot" + Write-Warning "Path not found: $componentRoot" } + - task: PowerShell@2 + displayName: Find VSTSDrop.json path + inputs: + targetType: inline + script: | + $componentRoot = Join-Path "$(Pipeline.Workspace)" "ComponentBuildUnderTest" + Write-Host "Searching for VSTSDrop.json under: $componentRoot" + if (-not (Test-Path -LiteralPath $componentRoot)) { + throw "ComponentBuildUnderTest root not found: $componentRoot" + } + + $matches = Get-ChildItem -LiteralPath $componentRoot -Recurse -Force -File -Filter "VSTSDrop.json" -ErrorAction SilentlyContinue + if (-not $matches) { + throw "No VSTSDrop.json found under: $componentRoot" + } + + if ($matches.Count -gt 1) { + Write-Warning "Multiple VSTSDrop.json files found; selecting the most recent." + $matches | Select-Object FullName, Length, LastWriteTime | Sort-Object LastWriteTime -Descending | Format-Table -AutoSize + } + + $selected = $matches | Sort-Object LastWriteTime -Descending | Select-Object -First 1 + Write-Host "Selected VSTSDrop.json: $($selected.FullName)" + Write-Host "##vso[task.setvariable variable=VSTSDropJsonURI]$($selected.FullName)" + - template: \steps\powershell\execute-script.yml@DartLabTemplates parameters: displayName: Set 'RunSettings.DropName' filePath: $(DartLab.Path)\Scripts\AzureDevOps\Artifacts\Drop\Get-DropName.ps1 - arguments: -VSTSDropJsonURI '$(Pipeline.Workspace)\ComponentBuildUnderTest\PTVS-TestData\VSTSDrop.json' -OutVariableName '$(Pipeline.Workspace)\ComponentBuildUnderTest\TestDataFolder\DDRITs.runsettings' + arguments: -VSTSDropJsonURI '$(VSTSDropJsonURI)' -OutVariableName 'RunSettings.DropName' \ No newline at end of file From bbe6294feeb678f62a207d7d83fc42ead7e556c7 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 4 Feb 2026 10:05:54 -0800 Subject: [PATCH 65/75] add timeout --- Python/Tests/PTVS.runsettingsproj | 1 + 1 file changed, 1 insertion(+) diff --git a/Python/Tests/PTVS.runsettingsproj b/Python/Tests/PTVS.runsettingsproj index f4d0a25f85..c4ec8363b2 100644 --- a/Python/Tests/PTVS.runsettingsproj +++ b/Python/Tests/PTVS.runsettingsproj @@ -4,6 +4,7 @@ net472 DDRITs bin\RunSettings + 3600000 From 3e663b14b2af7a659325cb13e8b3e5e1943ab80a Mon Sep 17 00:00:00 2001 From: bschnurr Date: Wed, 4 Feb 2026 19:31:28 -0800 Subject: [PATCH 66/75] add prints --- azure-pipelines-integration-testsgate.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index d6a124663e..b751bad487 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -174,4 +174,26 @@ stages: displayName: Set 'RunSettings.DropName' filePath: $(DartLab.Path)\Scripts\AzureDevOps\Artifacts\Drop\Get-DropName.ps1 arguments: -VSTSDropJsonURI '$(VSTSDropJsonURI)' -OutVariableName 'RunSettings.DropName' + + - task: PowerShell@2 + displayName: Debug arguments for 'Set RunSettings.DropName' + inputs: + targetType: inline + script: | + Write-Host "Resolved arguments for Get-DropName.ps1:" + Write-Host " -VSTSDropJsonURI '$($("VSTSDropJsonURI"))'" + Write-Host " -OutVariableName 'RunSettings.DropName'" + Write-Host "" + Write-Host "Raw argument string (as authored in YAML):" + Write-Host " -VSTSDropJsonURI '$(VSTSDropJsonURI)' -OutVariableName 'RunSettings.DropName'" + Write-Host "" + $path = "$(VSTSDropJsonURI)" + Write-Host "VSTSDropJsonURI points to: $path" + if ([string]::IsNullOrWhiteSpace($path)) { + Write-Warning "VSTSDropJsonURI is empty." + } elseif (Test-Path -LiteralPath $path) { + Write-Host "VSTSDropJsonURI exists on disk." + } else { + Write-Warning "VSTSDropJsonURI does not exist on disk (it may be a URI or incorrect path)." + } \ No newline at end of file From 61650c59b207f07a394c23e6a344fd75afe1c6c4 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 5 Feb 2026 14:28:59 -0800 Subject: [PATCH 67/75] use DDRITs.RunSettings --- azure-pipelines-integration-testsgate.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index b751bad487..a86d6ea569 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -40,7 +40,7 @@ stages: owner: ptvs testMachineLab: DDRITs-PR # This assumes the PTVS build has published a build artifact called "RunSettings" that contains the default.runsettings file - runSettingsURI: https://vsdrop.microsoft.com/file/v1/$(RunSettings.DropName);default.runsettings + runSettingsURI: https://vsdrop.microsoft.com/file/v1/$(RunSettings.DropName);DDRITs.runsettings visualStudioBootstrapperURI: $(VisualStudio.InstallationUnderTest.BootstrapperURL) visualStudioSigning: Test testMachineConfigurationJobVariables: From 8025d84352d6caae3f294417030639caed6ab09d Mon Sep 17 00:00:00 2001 From: bschnurr Date: Thu, 5 Feb 2026 15:49:12 -0800 Subject: [PATCH 68/75] lowercase dropfolder and ddrits name --- Build/templates/publish_test_data.yml | 6 +++--- azure-pipelines.yml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Build/templates/publish_test_data.yml b/Build/templates/publish_test_data.yml index 1d1e6d067a..402997a2cc 100644 --- a/Build/templates/publish_test_data.yml +++ b/Build/templates/publish_test_data.yml @@ -29,7 +29,7 @@ steps: $ErrorActionPreference = 'Stop' $source = "$(Build.SourcesDirectory)\Python\Tests\bin\RunSettings\DDRITs.runsettings" - $dest = "$(Build.SourcesDirectory)\Python\Tests\TestData\DDRITs.runsettings" + $dest = "$(Build.SourcesDirectory)\Python\Tests\TestData\ddrits.runsettings" if (-not (Test-Path -LiteralPath $source)) { throw "Expected generated runsettings file not found: $source" @@ -59,10 +59,10 @@ steps: TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' - task: CopyFiles@2 - displayName: 'Copy DDRITs.runsettings to subfolder' + displayName: 'Copy ddrits.runsettings to subfolder' inputs: SourceFolder: '$(Build.SourcesDirectory)/Python/Tests/TestData' - Contents: 'DDRITs.runsettings' + Contents: 'ddrits.runsettings' TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 36accd5e58..b48fdf8d0e 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -277,7 +277,7 @@ extends: - job: testdata displayName: Publish TestData variables: - TestDataDropName: "DevDiv/PTVS/Tests/$(Build.BuildNumber)/$(Build.BuildId)" + TestDataDropName: "devdiv/ptvs/tests/$(Build.BuildNumber)/$(Build.BuildId)" TestStoreDropName: "$(TestDataDropName)" templateContext: isProduction: false From 9c3c1a22aecfe949c8028bc1f8dfa88eee036214 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Fri, 6 Feb 2026 16:51:59 -0800 Subject: [PATCH 69/75] renname to ptvs.runtimesettings and try call extract on testdata.zip --- Build/azuredevops/test/uitest-integration-stage.yml | 6 +++--- Build/templates/publish_test_data.yml | 10 +++++----- Python/Tests/PTVS.runsettingsproj | 12 ++++++++++-- azure-pipelines-integration-testsgate.yml | 10 +++++++++- 4 files changed, 27 insertions(+), 11 deletions(-) diff --git a/Build/azuredevops/test/uitest-integration-stage.yml b/Build/azuredevops/test/uitest-integration-stage.yml index b248a2f879..b9ffb515d4 100644 --- a/Build/azuredevops/test/uitest-integration-stage.yml +++ b/Build/azuredevops/test/uitest-integration-stage.yml @@ -20,7 +20,7 @@ steps: displayName: Extract files condition: succeeded() inputs: - archiveFilePatterns: '${{ parameters.Drop }}/TestData/TestData.zip' + archiveFilePatterns: '${{ parameters.Drop }}/TestData.zip' destinationFolder: '${{ parameters.Drop }}/TestData' cleanDestinationFolder: false overwriteExistingFiles: false @@ -68,7 +68,7 @@ steps: condition: succeeded() inputs: SourceFolder: '${{ parameters.BinariesDirectory }}/TestData' - Contents: 'default.runsettings' + Contents: 'ptvs.runsettings' TargetFolder: '${{ parameters.BinariesDirectory }}' CleanTargetFolder: 'false' OverWrite: 'false' @@ -102,7 +102,7 @@ steps: uiTests: true vstestLocationMethod: version vsTestVersion: latest - runSettingsFile: '${{ parameters.BinariesDirectory }}/default.runsettings' + runSettingsFile: '${{ parameters.BinariesDirectory }}/ptvs.runsettings' overrideTestrunParameters: '-TargetFrameworkVersion .NETFramework,Version=v4.7.2' runInParallel: false runTestsInIsolation: false diff --git a/Build/templates/publish_test_data.yml b/Build/templates/publish_test_data.yml index 402997a2cc..462009249c 100644 --- a/Build/templates/publish_test_data.yml +++ b/Build/templates/publish_test_data.yml @@ -22,14 +22,14 @@ steps: /p:TestStoreDropName=$(TestStoreDropName) - task: PowerShell@2 - displayName: 'Update default.runsettings from generated DDRITs.runsettings' + displayName: 'Update default.runsettings from generated ptvs.runsettings' inputs: targetType: 'inline' script: | $ErrorActionPreference = 'Stop' - $source = "$(Build.SourcesDirectory)\Python\Tests\bin\RunSettings\DDRITs.runsettings" - $dest = "$(Build.SourcesDirectory)\Python\Tests\TestData\ddrits.runsettings" + $source = "$(Build.SourcesDirectory)\Python\Tests\bin\RunSettings\ptvs.runsettings" + $dest = "$(Build.SourcesDirectory)\Python\Tests\TestData\ptvs.runsettings" if (-not (Test-Path -LiteralPath $source)) { throw "Expected generated runsettings file not found: $source" @@ -59,10 +59,10 @@ steps: TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' - task: CopyFiles@2 - displayName: 'Copy ddrits.runsettings to subfolder' + displayName: 'Copy ptvs.runsettings to subfolder' inputs: SourceFolder: '$(Build.SourcesDirectory)/Python/Tests/TestData' - Contents: 'ddrits.runsettings' + Contents: 'ptvs.runsettings' TargetFolder: '$(Build.ArtifactStagingDirectory)/TestDataFolder' diff --git a/Python/Tests/PTVS.runsettingsproj b/Python/Tests/PTVS.runsettingsproj index c4ec8363b2..43ef9a6a18 100644 --- a/Python/Tests/PTVS.runsettingsproj +++ b/Python/Tests/PTVS.runsettingsproj @@ -1,13 +1,21 @@ - net472 - DDRITs + v4.6.1 + ptvs bin\RunSettings + .\TestResults + x86 + 1 3600000 + + + --> diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index a86d6ea569..9a6d20c314 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -40,7 +40,7 @@ stages: owner: ptvs testMachineLab: DDRITs-PR # This assumes the PTVS build has published a build artifact called "RunSettings" that contains the default.runsettings file - runSettingsURI: https://vsdrop.microsoft.com/file/v1/$(RunSettings.DropName);DDRITs.runsettings + runSettingsURI: https://vsdrop.microsoft.com/file/v1/$(RunSettings.DropName);ptvs.runsettings visualStudioBootstrapperURI: $(VisualStudio.InstallationUnderTest.BootstrapperURL) visualStudioSigning: Test testMachineConfigurationJobVariables: @@ -169,6 +169,14 @@ stages: Write-Host "Selected VSTSDrop.json: $($selected.FullName)" Write-Host "##vso[task.setvariable variable=VSTSDropJsonURI]$($selected.FullName)" + + - template: \build\azuredevops\test\uitest-integration-stage.yml + parameters: + BinariesDirectory: Run UI Tests + Drop: $(Pipeline.Workspace)\ComponentBuildUnderTest\ + TestFilterCriteria: $(Pipeline.Workspace)\UITestResults + UITestNames: PTVS UI Tests + - template: \steps\powershell\execute-script.yml@DartLabTemplates parameters: displayName: Set 'RunSettings.DropName' From 0133858a505affbadae7bec59d7904e9a5566ce2 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 9 Feb 2026 09:49:01 -0800 Subject: [PATCH 70/75] remove comment in comment --- Python/Tests/PTVS.runsettingsproj | 1 - 1 file changed, 1 deletion(-) diff --git a/Python/Tests/PTVS.runsettingsproj b/Python/Tests/PTVS.runsettingsproj index 43ef9a6a18..ff15a13040 100644 --- a/Python/Tests/PTVS.runsettingsproj +++ b/Python/Tests/PTVS.runsettingsproj @@ -13,7 +13,6 @@ --> From cd5cdfa38d3efa9c69f205cabd8dd8c5a448025a Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 9 Feb 2026 13:24:44 -0800 Subject: [PATCH 71/75] fix path to template --- azure-pipelines-integration-testsgate.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index 9a6d20c314..ac623f8d81 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -170,7 +170,7 @@ stages: Write-Host "##vso[task.setvariable variable=VSTSDropJsonURI]$($selected.FullName)" - - template: \build\azuredevops\test\uitest-integration-stage.yml + - template: Build/azuredevops/test/uitest-integration-stage.yml parameters: BinariesDirectory: Run UI Tests Drop: $(Pipeline.Workspace)\ComponentBuildUnderTest\ From fec1f850aef2224178dfc13fa83a5e704bd33397 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 9 Feb 2026 13:30:12 -0800 Subject: [PATCH 72/75] =?UTF-8?q?Fixed=20the=20ExtractFiles@1=20ENOENT=20b?= =?UTF-8?q?y=20making=20the=20UI-test=20template=E2=80=99s=20Drop=20parame?= =?UTF-8?q?ter=20point=20at=20the=20folder=20that=20actually=20contains=20?= =?UTF-8?q?TestData.zip=20after=20artifact=20download=20(and=20removed=20t?= =?UTF-8?q?he=20trailing=20slash=20that=20produced=20\/=20in=20the=20resol?= =?UTF-8?q?ved=20path).=20Added=20an=20explicit=20download=20of=20the=20Bi?= =?UTF-8?q?naries=20artifact=20and=20set=20BinariesDirectory=20to=20that?= =?UTF-8?q?=20folder.=20Corrected=20the=20obviously-wrong=20template=20par?= =?UTF-8?q?ameters=20(TestFilterCriteria=20was=20a=20path;=20UITestNames?= =?UTF-8?q?=20contained=20spaces=20and=20wouldn=E2=80=99t=20form=20a=20val?= =?UTF-8?q?id=20*UITestsRunner.dll).?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- azure-pipelines-integration-testsgate.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/azure-pipelines-integration-testsgate.yml b/azure-pipelines-integration-testsgate.yml index ac623f8d81..b6c17dc596 100644 --- a/azure-pipelines-integration-testsgate.yml +++ b/azure-pipelines-integration-testsgate.yml @@ -71,6 +71,11 @@ stages: patterns: '**\*' displayName: Download TestDataFolder Information + - download: ComponentBuildUnderTest + artifact: Binaries + patterns: '**\*' + displayName: Download Binaries + - task: PowerShell@2 displayName: List downloaded files before setting 'RunSettings.DropName' inputs: @@ -172,10 +177,9 @@ stages: - template: Build/azuredevops/test/uitest-integration-stage.yml parameters: - BinariesDirectory: Run UI Tests - Drop: $(Pipeline.Workspace)\ComponentBuildUnderTest\ - TestFilterCriteria: $(Pipeline.Workspace)\UITestResults - UITestNames: PTVS UI Tests + BinariesDirectory: $(Pipeline.Workspace)\ComponentBuildUnderTest\Binaries + Drop: $(Pipeline.Workspace)\ComponentBuildUnderTest\TestDataFolder + UITestNames: PythonTools - template: \steps\powershell\execute-script.yml@DartLabTemplates parameters: From df17bf049346050c9d337058bea841d68ce66fa9 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 9 Feb 2026 13:48:35 -0800 Subject: [PATCH 73/75] try to fix cleanup --- .../test/uitest-integration-stage.yml | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/Build/azuredevops/test/uitest-integration-stage.yml b/Build/azuredevops/test/uitest-integration-stage.yml index b9ffb515d4..9a7e070491 100644 --- a/Build/azuredevops/test/uitest-integration-stage.yml +++ b/Build/azuredevops/test/uitest-integration-stage.yml @@ -32,9 +32,13 @@ steps: timeoutInMinutes: 5 inputs: targetType: inline - arguments: '${{ parameters.CleanupProcesses }}' script: | - param ([string[]]$names) + $names = @( + '${{ parameters.CleanupProcesses }}' + -split ',' | + ForEach-Object { $_.Trim() } | + Where-Object { -not [string]::IsNullOrWhiteSpace($_) } + ) $running = Get-Process -Name $names -ErrorAction SilentlyContinue while ($running) { Write-Host 'Killing:' @@ -131,9 +135,13 @@ steps: timeoutInMinutes: 5 inputs: targetType: inline - arguments: '${{ parameters.CleanupProcesses }}' script: | - param ([string[]]$names) + $names = @( + '${{ parameters.CleanupProcesses }}' + -split ',' | + ForEach-Object { $_.Trim() } | + Where-Object { -not [string]::IsNullOrWhiteSpace($_) } + ) $running = Get-Process -Name $names -ErrorAction SilentlyContinue while ($running) { Write-Host 'Killing:' From ea810ca4caea111236bbcd52c8b1a8fcce8b9c74 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 9 Feb 2026 14:09:59 -0800 Subject: [PATCH 74/75] fix ptvs.runsettings path --- Build/azuredevops/test/uitest-integration-stage.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Build/azuredevops/test/uitest-integration-stage.yml b/Build/azuredevops/test/uitest-integration-stage.yml index 9a7e070491..1781f40ab8 100644 --- a/Build/azuredevops/test/uitest-integration-stage.yml +++ b/Build/azuredevops/test/uitest-integration-stage.yml @@ -106,7 +106,7 @@ steps: uiTests: true vstestLocationMethod: version vsTestVersion: latest - runSettingsFile: '${{ parameters.BinariesDirectory }}/ptvs.runsettings' + runSettingsFile: '${{ parameters.BinariesDirectory }}\\TestData\\ptvs.runsettings' overrideTestrunParameters: '-TargetFrameworkVersion .NETFramework,Version=v4.7.2' runInParallel: false runTestsInIsolation: false From 90f6ed3eb878df5173c5fee9464d3b44d9737e60 Mon Sep 17 00:00:00 2001 From: bschnurr Date: Mon, 9 Feb 2026 15:37:47 -0800 Subject: [PATCH 75/75] change ptvs.runsettings path again --- Build/azuredevops/test/uitest-integration-stage.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Build/azuredevops/test/uitest-integration-stage.yml b/Build/azuredevops/test/uitest-integration-stage.yml index 1781f40ab8..07372455b8 100644 --- a/Build/azuredevops/test/uitest-integration-stage.yml +++ b/Build/azuredevops/test/uitest-integration-stage.yml @@ -106,7 +106,7 @@ steps: uiTests: true vstestLocationMethod: version vsTestVersion: latest - runSettingsFile: '${{ parameters.BinariesDirectory }}\\TestData\\ptvs.runsettings' + runSettingsFile: '${{ parameters.Drop }}\\ptvs.runsettings' overrideTestrunParameters: '-TargetFrameworkVersion .NETFramework,Version=v4.7.2' runInParallel: false runTestsInIsolation: false