testutil

package
v1.25.4 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2024 License: Apache-2.0 Imports: 14 Imported by: 11

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ConfigPlanChecks = func(resourceName string) resource.ConfigPlanChecks {
	return resource.ConfigPlanChecks{
		PostApplyPreRefresh: []plancheck.PlanCheck{
			DebugPlan(resourceName, "PostApplyPreRefresh"),
		},
		PostApplyPostRefresh: []plancheck.PlanCheck{
			DebugPlan(resourceName, "PostApplyPostRefresh"),
		},
	}
}

Functions

func DebugPlan added in v1.25.0

func DebugPlan(resourceName, stage string) plancheck.PlanCheck

func GetEnvVarWithFallback

func GetEnvVarWithFallback(t *testing.T, envVars ...string) string

func MapToTestChecks

func MapToTestChecks(fqrn string, fields map[string]interface{}) []resource.TestCheckFunc

func MkNames

func MkNames(name, resource string) (int, string, string)

func RandBool

func RandBool() bool

func RandSelect

func RandSelect(items ...interface{}) interface{}

func RandomInt

func RandomInt() int

Types

type CheckFun

type CheckFun func(id string, request *resty.Request) (*resty.Response, error)

type PlanCheck added in v1.25.0

type PlanCheck struct {
	Stage        string
	ResourceName string
}

func (PlanCheck) CheckPlan added in v1.25.0

Jump to

Keyboard shortcuts

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