test

package
v0.0.0-...-604a9e0 Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const DownloadedLXCTemplate string = "alpine-3.17-default_20221129_amd64.tar.xz"
View Source
const FirstNode string = "pve"

Variables

This section is empty.

Functions

func ListTest

func ListTest(t *testing.T, args []string, expected string)

func SetEnvironmentVariables

func SetEnvironmentVariables()

Types

type LoginTest

type LoginTest struct {
	APIurl      string
	UserID      string
	Password    string
	OTP         string
	HttpHeaders string
	ReqErr      bool //if an error is expected as output
}

func (*LoginTest) Login

func (test *LoginTest) Login(t *testing.T)

type Test

type Test struct {
	InputJson  any //the inputted json
	OutputJson any //the outputted json

	Expected string   //matches the output exactly
	Contains []string //the output contains all of the strings

	NotExpected string   //the output that is not expected
	NotContains []string //the output may not contain any of these strings

	ReqErr      bool   //if an error is expected as output
	ErrContains string //the string the error should contain

	// TODO remove is obsolete
	Return bool //if the output should be read and returned for more advanced processing

	Args []string //cli arguments
}

func (*Test) StandardTest

func (test *Test) StandardTest(t *testing.T) (out []byte)

Directories

Path Synopsis
Group
Storage
Users

Jump to

Keyboard shortcuts

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