From 97e8330bddfd9801894ce53b2e50c2c572914076 Mon Sep 17 00:00:00 2001 From: Sergio Pedri Date: Wed, 13 Nov 2024 17:32:49 -0800 Subject: [PATCH] Fix failing tests using "UseUwp" --- .../GivenThatWeWantToBuildAWindowsDesktopProject.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/Microsoft.NET.Build.Tests/GivenThatWeWantToBuildAWindowsDesktopProject.cs b/test/Microsoft.NET.Build.Tests/GivenThatWeWantToBuildAWindowsDesktopProject.cs index 6c3dac9ca3f5..46f9c2a07fa5 100644 --- a/test/Microsoft.NET.Build.Tests/GivenThatWeWantToBuildAWindowsDesktopProject.cs +++ b/test/Microsoft.NET.Build.Tests/GivenThatWeWantToBuildAWindowsDesktopProject.cs @@ -463,6 +463,7 @@ public void ItWarnsWhenBuildingAProjectWithUseUwpProperty() TargetFrameworks = "net9.0-windows10.0.22621.0" }; testProject.AdditionalProperties["UseUwp"] = "true"; + testProject.AdditionalProperties["UseUwpTools"] = "false"; var testAsset = _testAssetsManager.CreateTestProject(testProject); @@ -484,6 +485,7 @@ public void ItErrorsWhenTargetingBelowNet6WithUseUwpProperty() TargetFrameworks = "netstandard2.0" }; testProject.AdditionalProperties["UseUwp"] = "true"; + testProject.AdditionalProperties["UseUwpTools"] = "false"; var testAsset = _testAssetsManager.CreateTestProject(testProject); @@ -505,6 +507,7 @@ public void ItErrorsWhenTransitivelyReferencingWindowsUIXamlReferencesWithoutUse TargetFrameworks = "net9.0-windows10.0.22621.0" }; testProjectA.AdditionalProperties["UseUwp"] = "true"; + testProjectA.AdditionalProperties["UseUwpTools"] = "false"; TestProject testProjectB = new() { @@ -579,6 +582,7 @@ public void ItBuildsWhenReferencingWindowsUIXamlTypesWithUseUwpProperty() } }; testProject.AdditionalProperties["UseUwp"] = "true"; + testProject.AdditionalProperties["UseUwpTools"] = "false"; // Temporary until new projections flow to tests testProject.AdditionalProperties["WindowsSdkPackageVersion"] = "10.0.22621.39";