From 2a017022372d9567b3b6a7ee3f0668796ee4db74 Mon Sep 17 00:00:00 2001 From: Junjie Gao Date: Fri, 31 May 2024 10:23:27 +0800 Subject: [PATCH] fix: revert test Signed-off-by: Junjie Gao --- notation_test.go | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/notation_test.go b/notation_test.go index 32805d22..8b9c45c3 100644 --- a/notation_test.go +++ b/notation_test.go @@ -188,37 +188,6 @@ func TestSignWithInvalidUserMetadata(t *testing.T) { } } -func TestSignOptsMissingSignatureMediaType(t *testing.T) { - repo := mock.NewRepository() - opts := SignOptions{ - SignerSignOptions: SignerSignOptions{ - SignatureMediaType: "", - }, - ArtifactReference: mock.SampleArtifactUri, - } - - _, err := Sign(context.Background(), &dummySigner{}, repo, opts) - if err == nil { - t.Fatalf("expected error but not found") - } -} - -func TestSignOptsUnknownMediaType(t *testing.T) { - repo := mock.NewRepository() - opts := SignOptions{ - SignerSignOptions: SignerSignOptions{ - SignatureMediaType: "unknown", - }, - ArtifactReference: mock.SampleArtifactUri, - } - - _, err := Sign(context.Background(), &dummySigner{}, repo, opts) - if err == nil { - t.Fatalf("expected error but not found") - } - -} - func TestRegistryResolveError(t *testing.T) { policyDocument := dummyPolicyDocument() repo := mock.NewRepository()