testkit

package
v0.0.0-...-5f509e1 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: Apache-2.0 Imports: 17 Imported by: 2

Documentation

Index

Constants

View Source
const (
	Azure = "Azure"
	GCP   = "GCP"
)

Variables

This section is empty.

Functions

func CreateGardenerProvisioningInput

func CreateGardenerProvisioningInput(config *TestConfig, version, provider string) (gqlschema.ProvisionRuntimeInput, error)

func CreateGardenerUpgradeInput

func CreateGardenerUpgradeInput(config *TestConfig) *gqlschema.UpgradeShootInput

func CreateKymaConfigInput

func CreateKymaConfigInput(version string) (*gqlschema.KymaConfigInput, error)

func GetAndParseInstallerCR

func GetAndParseInstallerCR(installationCRURL string) ([]*gqlschema.ComponentConfigurationInput, error)

func IsTillerPresent

func IsTillerPresent(httpClient http.Client, kymaVersion string) (bool, error)

func WaitForFunction

func WaitForFunction(interval, timeout time.Duration, isDone func() bool) error

Types

type DirectorClientConfig

type DirectorClientConfig struct {
	URL                        string `envconfig:"default=http://compass-director.compass-system.svc.cluster.local:3000/graphql"`
	Namespace                  string `envconfig:"default=kcp-system"`
	OauthCredentialsSecretName string `envconfig:"default=kcp-provisioner-credentials"`
}

type GardenerConfig

type GardenerConfig struct {
	Providers   []string `envconfig:"default=Azure"`
	AzureSecret string   `envconfig:"default=''"`
	GCPSecret   string   `envconfig:"default=''"`
}

type KymaConfig

type KymaConfig struct {
	Version string `envconfig:"default=1.11.0"`
	// PreUpgradeVersion is used in upgrade test
	PreUpgradeVersion string `envconfig:"default=1.10.0"`
}

type Logger

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

func NewLogger

func NewLogger(t *testing.T, fields logrus.Fields) *Logger

func (Logger) Error

func (l Logger) Error(msg string)

func (Logger) Errorf

func (l Logger) Errorf(format string, msg ...interface{})

func (Logger) Log

func (l Logger) Log(msg string)

func (Logger) Logf

func (l Logger) Logf(format string, msg ...interface{})

func (*Logger) WithField

func (l *Logger) WithField(key string, value interface{})

type TestConfig

type TestConfig struct {
	InternalProvisionerURL string `envconfig:"default=http://localhost:3000/graphql"`
	Tenant                 string `envconfig:"default=3e64ebae-38b5-46a0-b1ed-9ccee153a0ae"`

	Gardener       GardenerConfig
	DirectorClient DirectorClientConfig
	Kyma           KymaConfig

	KubernetesVersion        string `envconfig:"default=1.17.8"`
	UpgradeKubernetesVersion string `envconfig:"default=1.18.5"`

	QueryLogging bool `envconfig:"default=false"`

	Timeouts Timeouts
}

func ReadConfig

func ReadConfig() (TestConfig, error)

func (TestConfig) String

func (c TestConfig) String() string

type Timeouts

type Timeouts struct {
	Provisioning   time.Duration `envconfig:"default=4h"`
	Upgrade        time.Duration `envconfig:"default=4h"`
	UpgradeShoot   time.Duration `envconfig:"default=4h"`
	Deprovisioning time.Duration `envconfig:"default=4h"`
	Hibernation    time.Duration `envconfig:"default=30m"`
}

Directories

Path Synopsis
compass
control-plane

Jump to

Keyboard shortcuts

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