test

package
v6.5.0 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2024 License: MPL-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package test contains reusable structure and functions used during testing of sub-providers

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImportChecker

type ImportChecker struct {
	// contains filtered or unexported fields
}

ImportChecker allows to check the attributes in the state after terraform import.

func NewImportChecker

func NewImportChecker() ImportChecker

NewImportChecker creates a new instance of a ImportChecker that checks attributes for provided resource name after the resource is imported.

func (ImportChecker) Build

Build processes all attributes and creates checks for them based on assigned values.

func (ImportChecker) CheckEqual

func (c ImportChecker) CheckEqual(attr, val string) ImportChecker

CheckEqual adds a check for provided attribute name and corresponding value.

func (ImportChecker) CheckMissing

func (c ImportChecker) CheckMissing(attr string) ImportChecker

CheckMissing adds a check for a provided attribute name to not be present in the state.

type StateChecker

type StateChecker struct {
	// contains filtered or unexported fields
}

StateChecker allows to check the attributes in the terraform state.

func NewStateChecker

func NewStateChecker(resourceName string) StateChecker

NewStateChecker creates a new instance of a StateChecker that checks attributes for a resource with provided name.

func (StateChecker) Build

Build processes all attributes and creates checks for them based on assigned values.

func (StateChecker) CheckEqual

func (c StateChecker) CheckEqual(attr, val string) StateChecker

CheckEqual adds a check for provided attribute name and corresponding value.

func (StateChecker) CheckMissing

func (c StateChecker) CheckMissing(attr string) StateChecker

CheckMissing adds a check for a provided attribute name to not be present in the state.

Jump to

Keyboard shortcuts

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