Skip to content

Commit

Permalink
Disable verification during extraction for Mono, disable a test on Mo…
Browse files Browse the repository at this point in the history
…no (#3451)

* disable verification during extraction on mono,disable a mono test on Mac
  • Loading branch information
heng-liu committed Jun 19, 2020
1 parent c4a13dd commit dc9e720
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion src/NuGet.Core/NuGet.Packaging/PackageArchiveReader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,16 @@ public override Task<byte[]> GetArchiveHashAsync(HashAlgorithmName hashAlgorithm
public override bool CanVerifySignedPackages(SignedPackageVerifierSettings verifierSettings)
{
#if IS_SIGNING_SUPPORTED
return true;
// Mono support has been deprioritized, so verification on Mono is not enabled, tracking issue: https://github.com/NuGet/Home/issues/9027
if (RuntimeEnvironmentHelper.IsMono)
{
return false;
}
else
{
return true;
}

#else
return false;
#endif
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public void VerifyCommand_WrongInput_NotFound()
}
}

[Fact]
[PlatformFact(Platform.Windows, SkipMono = true)]
public void VerifyCommand_WithAuthorSignedPackage_FailsGracefully()
{
var nugetExe = Util.GetNuGetExePath();
Expand Down

0 comments on commit dc9e720

Please sign in to comment.