testutil

package
v0.0.0-...-e405fbd Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Blob

type Blob struct {
	Descriptor ocispec.Descriptor
	Data       []byte
}

func Config

func Config(img ocispec.Image) (*Blob, error)

func Index

func Index(idx ocispec.Index) (*Blob, error)

func Manifest

func Manifest(mfst ocispec.Manifest) (*Blob, error)

type Env

type Env struct {
	// contains filtered or unexported fields
}

func NewEnv

func NewEnv(t *testing.T) *Env

func (*Env) AddBlob

func (e *Env) AddBlob(b *Blob) (digest.Digest, error)

func (*Env) AddTag

func (e *Env) AddTag(ref string, dgst digest.Digest) error

func (*Env) Fetch

func (e *Env) Fetch(ctx context.Context, desc ocispec.Descriptor) (io.ReadCloser, error)

func (*Env) Fetcher

func (e *Env) Fetcher(ctx context.Context, ref string) (remotes.Fetcher, error)

func (*Env) Pusher

func (e *Env) Pusher(ctx context.Context, ref string) (remotes.Pusher, error)

func (*Env) Resolve

func (e *Env) Resolve(ctx context.Context, ref string) (name string, desc ocispec.Descriptor, err error)

Jump to

Keyboard shortcuts

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