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.
This commit is contained in:
Nate McMaster 2018-04-19 12:07:55 -07:00 committed by Nate McMaster
parent e06b1fd690
commit 30928ba944
No known key found for this signature in database
GPG Key ID: A778D9601BD78810
1 changed files with 5 additions and 1 deletions

View File

@ -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)
{