e2e

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const POLLING = "250ms"
View Source
const TIMEOUT = "60s"

Variables

This section is empty.

Functions

This section is empty.

Types

type Harness

type Harness struct {
	VM      vm.TestVMInterface
	Client  *apiclient.ClientWithResponses
	Context context.Context
	// contains filtered or unexported fields
}

func NewTestHarness

func NewTestHarness() *Harness

func (*Harness) ApiEndpoint

func (h *Harness) ApiEndpoint() string

func (*Harness) ApproveEnrollment

func (h *Harness) ApproveEnrollment(id string, approval *v1alpha1.EnrollmentRequestApproval)

func (*Harness) CLI

func (h *Harness) CLI(args ...string) (string, error)

func (*Harness) CLIWithStdin

func (h *Harness) CLIWithStdin(stdin string, args ...string) (string, error)

func (*Harness) Cleanup

func (h *Harness) Cleanup(printConsole bool)

Harness cleanup, this will delete the VM and cancel the context if something failed we try to gather logs, console logs are optional and can be enabled by setting printConsole to true

func (*Harness) GetDeviceWithStatusSystem

func (h *Harness) GetDeviceWithStatusSystem(enrollmentID string) *apiclient.ReadDeviceResponse

func (*Harness) GetEnrollmentIDFromConsole

func (h *Harness) GetEnrollmentIDFromConsole() string

func (*Harness) RunInteractiveCLI

func (h *Harness) RunInteractiveCLI(args ...string) (io.WriteCloser, io.ReadCloser, error)

func (*Harness) StartVMAndEnroll

func (h *Harness) StartVMAndEnroll() string

func (*Harness) WaitForEnrollmentRequest

func (h *Harness) WaitForEnrollmentRequest(id string) *v1alpha1.EnrollmentRequest

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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