From 30928ba944ed398167eda63ec34d63bcc1d515f8 Mon Sep 17 00:00:00 2001 From: Nate McMaster Date: Thu, 19 Apr 2018 12:07:55 -0700 Subject: [PATCH] Disable implicit package version verification when --no-restore is used Workaround an error when building in ProdCon where the RuntimeFrameworkVersion is overridden externally. Generally, the error is good, but when --no-restore is specified, we are okay ignoring this verification. --- .../Deployers/ApplicationDeployer.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Microsoft.AspNetCore.Server.IntegrationTesting/Deployers/ApplicationDeployer.cs b/src/Microsoft.AspNetCore.Server.IntegrationTesting/Deployers/ApplicationDeployer.cs index 15aa255e33..3c81f32902 100644 --- a/src/Microsoft.AspNetCore.Server.IntegrationTesting/Deployers/ApplicationDeployer.cs +++ b/src/Microsoft.AspNetCore.Server.IntegrationTesting/Deployers/ApplicationDeployer.cs @@ -55,7 +55,11 @@ namespace Microsoft.AspNetCore.Server.IntegrationTesting + $" --output \"{DeploymentParameters.PublishedApplicationRootPath}\"" + $" --framework {DeploymentParameters.TargetFramework}" + $" --configuration {DeploymentParameters.Configuration}" - + (DeploymentParameters.RestoreOnPublish ? "" : " --no-restore"); + + (DeploymentParameters.RestoreOnPublish + ? string.Empty + : " --no-restore -p:VerifyMatchingImplicitPackageVersion=false"); + // Set VerifyMatchingImplicitPackageVersion to disable errors when Microsoft.NETCore.App's version is overridden externally + // This verification doesn't matter if we are skipping restore during tests. if (DeploymentParameters.ApplicationType == ApplicationType.Standalone) {