Skip to content

Commit

Permalink
Fix test by not restoring and avoiding a different error that's more …
Browse files Browse the repository at this point in the history
…confusing
  • Loading branch information
marcpopMSFT authored Dec 2, 2022
1 parent b0c6d3b commit 93822ea
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,11 @@ public void It_errors_when_missing_windows_target_platform(string propertyName)
testProject.AdditionalProperties[propertyName] = "true";
testProject.AdditionalProperties["TargetPlatformIdentifier"] = "custom"; // Make sure we don't get windows implicitly set as the TPI
testProject.AdditionalProperties["TargetPlatformSupported"] = "true";
testProject.AdditionalProperties["TargetPlatformMoniker"] = "custom,Version="; //Make sure we avoid implicitly setting an invalid TPV
var testAsset = _testAssetsManager.CreateTestProject(testProject, identifier: propertyName);

var buildCommand = new BuildCommand(testAsset);
buildCommand.Execute()
buildCommand.ExecuteWithoutRestore()
.Should()
.Fail()
.And
Expand Down

0 comments on commit 93822ea

Please sign in to comment.