testhelpers

package
v0.0.0-...-c7d747a Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2023 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToYAML

func ToYAML[T any](h *Harness, items []T) string

Types

type Harness

type Harness struct {
	*testing.T

	Ctx context.Context
}

func NewHarness

func NewHarness(t *testing.T) *Harness

func (*Harness) AssertMatchesFile

func (h *Harness) AssertMatchesFile(p string, got string)

func (*Harness) MustReadFile

func (h *Harness) MustReadFile(p string) []byte

func (*Harness) ParseObjects

func (h *Harness) ParseObjects(y string) []*unstructured.Unstructured

func (*Harness) ParseOneObject

func (h *Harness) ParseOneObject(y string) *unstructured.Unstructured

func (*Harness) StartOCIServer

func (h *Harness) StartOCIServer() *oci.Server

Jump to

Keyboard shortcuts

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