testhelpers

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2018 License: MPL-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeriveActiveCore

func DeriveActiveCore(t testing.T, cluster *vault.TestCluster) *vault.TestClusterCore

func EnsureCoresUnsealed

func EnsureCoresUnsealed(t testing.T, c *vault.TestCluster)

func GenerateRoot

func GenerateRoot(t testing.T, cluster *vault.TestCluster, drToken bool) string

Generates a root token on the target cluster.

func GenerateRootWithError

func GenerateRootWithError(t testing.T, cluster *vault.TestCluster, drToken bool) (string, error)

func GetClusterAndCore

func GetClusterAndCore(t testing.T, logger log.Logger) (*vault.TestCluster, *vault.TestClusterCore)

func RandomWithPrefix

func RandomWithPrefix(name string) string

RandomWithPrefix is used to generate a unique name with a prefix, for randomizing names in acceptance tests

func SetupFourClusterReplication

func SetupFourClusterReplication(t testing.T, perfPrimary, perfSecondary, perfDRSecondary, perfSecondaryDRSecondary *vault.TestCluster)

func WaitForNCoresSealed

func WaitForNCoresSealed(t testing.T, cluster *vault.TestCluster, n int)

func WaitForReplicationState

func WaitForReplicationState(t testing.T, c *vault.Core, state consts.ReplicationState)

Types

type ReplicatedTestClusters

type ReplicatedTestClusters struct {
	PerfPrimaryCluster     *vault.TestCluster
	PerfSecondaryCluster   *vault.TestCluster
	PerfPrimaryDRCluster   *vault.TestCluster
	PerfSecondaryDRCluster *vault.TestCluster
}

func GetFourReplicatedClusters

func GetFourReplicatedClusters(t testing.T) *ReplicatedTestClusters

func (*ReplicatedTestClusters) Cleanup

func (r *ReplicatedTestClusters) Cleanup()

Jump to

Keyboard shortcuts

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