testrun

package
v0.0.0-...-02c6b06 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2024 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseKubeconfigs

func ParseKubeconfigs(ctx context.Context, reader client.Reader, tr *tmv1beta1.Testrun) ([]*config.Element, []client.Object, map[string]*node.ProjectedTokenMount, error)

ParseKubeconfigs parses the kubeconfigs defined in the testrun and returns respective configs and k8s secrets.

func Validate

func Validate(log logr.Logger, tr *tmv1beta1.Testrun) (error, bool)

Validate validates a testrun. Returns if the validation can be retried

Types

type Testrun

type Testrun struct {
	Info            *tmv1beta1.Testrun
	Testflow        *testflow.Testflow
	OnExitTestflow  *testflow.Testflow
	HelperResources []client.Object
	ProjectedTokens map[string]*node.ProjectedTokenMount
}

Testrun is the internal representation of a testrun crd

func New

func New(ctx context.Context, log logr.Logger, tr *tmv1beta1.Testrun, reader client.Reader) (*Testrun, error)

New takes a testrun crd and creates a new Testrun representation. It fetches testruns from specified testdeflocations and generates a testflow object.

func (*Testrun) GetWorkflow

func (tr *Testrun) GetWorkflow(name, namespace string, pullImageSecretNames []string) (*argov1.Workflow, error)

GetWorkflow returns the argo workflow object of this testrun.

Jump to

Keyboard shortcuts

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