mocks

package
v1.0.0-rc.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 12, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TestSubjectWithDigest = "localhost:5000/net-monitor:v1@sha256:b556844e6e59451caf4429eb1de50aa7c50e4b1cc985f9f5893affe4b73f9935"
	SbomArtifactType      = "org.example.sbom.v0"
	SignatureArtifactType = "application/vnd.cncf.notary.signature"
)

Variables

This section is empty.

Functions

func CreateNewTestStoreForNestedSbom

func CreateNewTestStoreForNestedSbom() referrerstore.ReferrerStore

Types

type TestStore

type TestStore struct {
	References   []ocispecs.ReferenceDescriptor
	ResolveMap   map[string]digest.Digest
	ExtraSubject string
}

func (*TestStore) GetBlobContent

func (s *TestStore) GetBlobContent(ctx context.Context, subjectReference common.Reference, digest digest.Digest) ([]byte, error)

func (*TestStore) GetConfig

func (s *TestStore) GetConfig() *config.StoreConfig

func (*TestStore) GetReferenceManifest

func (s *TestStore) GetReferenceManifest(ctx context.Context, subjectReference common.Reference, referenceDesc ocispecs.ReferenceDescriptor) (ocispecs.ReferenceManifest, error)

func (*TestStore) GetSubjectDescriptor

func (s *TestStore) GetSubjectDescriptor(ctx context.Context, subjectReference common.Reference) (*ocispecs.SubjectDescriptor, error)

func (*TestStore) ListReferrers

func (s *TestStore) ListReferrers(ctx context.Context, subjectReference common.Reference, artifactTypes []string, nextToken string, subjectDesc *ocispecs.SubjectDescriptor) (referrerstore.ListReferrersResult, error)

func (*TestStore) Name

func (s *TestStore) Name() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL