Documentation ¶
Index ¶
- type CommonFrameworkLandscaper
- func (f *CommonFrameworkLandscaper) BeforeEach()
- func (f *CommonFrameworkLandscaper) CreateConfigMap(ctx context.Context, name string, data map[string]string) error
- func (f *CommonFrameworkLandscaper) CreateTargetWithKubeconfig(ctx context.Context, name, kubeconfigPath string) error
- func (f *CommonFrameworkLandscaper) DeleteConfigMap(ctx context.Context, name string) error
- func (f *CommonFrameworkLandscaper) DeleteInstallation(ctx context.Context, name string) error
- func (f *CommonFrameworkLandscaper) DeleteTarget(ctx context.Context, name string) error
- func (f *CommonFrameworkLandscaper) GetInstallation(name string) *landscaperv1alpha1.Installation
- type ComponentConfig
- type GardenletConfig
- type GardenletFramework
- func (f *GardenletFramework) BeforeEach()
- func (f *GardenletFramework) CreateInstallation(ctx context.Context) (*landscaperv1alpha1.Installation, error)
- func (f *GardenletFramework) CreateInstallationImports(ctx context.Context) error
- func (f *GardenletFramework) DeleteInstallationResources(ctx context.Context) error
- type LandscaperCommonConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommonFrameworkLandscaper ¶
type CommonFrameworkLandscaper struct { TestDescription Config *LandscaperCommonConfig Logger *logrus.Entry LandscaperClient client.Client // ResourceSuffix is a random suffix for landscaper resources created // by this integration test ResourceSuffix string }
CommonFrameworkLandscaper is a common framework for the testing of landscaper components.
func NewLandscaperCommonFramework ¶
func NewLandscaperCommonFramework(cfg *LandscaperCommonConfig) *CommonFrameworkLandscaper
NewLandscaperCommonFramework creates a new landscaper common framework.
func (*CommonFrameworkLandscaper) BeforeEach ¶
func (f *CommonFrameworkLandscaper) BeforeEach()
BeforeEach should be called in ginkgo's BeforeEach. It merges the landscaper configuration with the configuration from flags and creates the landscaper client
func (*CommonFrameworkLandscaper) CreateConfigMap ¶
func (f *CommonFrameworkLandscaper) CreateConfigMap(ctx context.Context, name string, data map[string]string) error
CreateConfigMap creates a new config map with retries
func (*CommonFrameworkLandscaper) CreateTargetWithKubeconfig ¶
func (f *CommonFrameworkLandscaper) CreateTargetWithKubeconfig(ctx context.Context, name, kubeconfigPath string) error
CreateTargetWithKubeconfig creates the landscaper target from a given name and kubeconfig path on the local filesystem
func (*CommonFrameworkLandscaper) DeleteConfigMap ¶
func (f *CommonFrameworkLandscaper) DeleteConfigMap(ctx context.Context, name string) error
DeleteConfigMap deletes a given config map resource with retries
func (*CommonFrameworkLandscaper) DeleteInstallation ¶
func (f *CommonFrameworkLandscaper) DeleteInstallation(ctx context.Context, name string) error
DeleteInstallation deletes the given installation and waits for it to be deleted.
func (*CommonFrameworkLandscaper) DeleteTarget ¶
func (f *CommonFrameworkLandscaper) DeleteTarget(ctx context.Context, name string) error
DeleteTarget deletes a given target resource with retries
func (*CommonFrameworkLandscaper) GetInstallation ¶
func (f *CommonFrameworkLandscaper) GetInstallation(name string) *landscaperv1alpha1.Installation
GetInstallation creates and returns a landscaperv1alpha1.Installation for the given name.
type ComponentConfig ¶
type ComponentConfig struct {
// contains filtered or unexported fields
}
ComponentConfig contains all the information to uniquely identify a component descriptor in a registry landscaper tests create Installation CRDs referencing this component descriptor this implies that prior to the test execution, the component descriptor must already exist in the registry and must reference a blueprint.
type GardenletConfig ¶
type GardenletConfig struct { SeedKubeconfigPath string ImageVectorOverwrite *string ComponentImageVectorOverwrites *string DeploymentConfiguration *seedmanagementv1alpha1.GardenletDeployment GardenerConfig *GardenerConfig LandscaperCommonConfig *LandscaperCommonConfig }
GardenletConfig is the configuration of the gardenlet landscaper component.
func RegisterGardenletFrameworkFlags ¶
func RegisterGardenletFrameworkFlags() *GardenletConfig
RegisterGardenletFrameworkFlags adds all flags that are needed to configure a landscaper gardenlet framework to the provided flagset.
type GardenletFramework ¶
type GardenletFramework struct { TestDescription *CommonFrameworkLandscaper *GardenerFramework Config *GardenletConfig SeedClient client.Client // GardenletConfiguration contains the Gardenlet's configuration // that is contained in a config map and imported in the Installation CRD // to be read by the Landscaper gardenlet as part of its imports configuration // (landscaper/gardenlet/pkg/apis/imports/types.go) // exposed to create test cases based on the configuration ComponentConfiguration *configv1alpha1.GardenletConfiguration }
GardenletFramework is a framework for the testing the gardenlet landscaper component.
func NewGardenletFramework ¶
func NewGardenletFramework(cfg *GardenletConfig) *GardenletFramework
NewGardenletFramework creates a new GardenletFramework.
func (*GardenletFramework) BeforeEach ¶
func (f *GardenletFramework) BeforeEach()
BeforeEach should be called in ginkgo's BeforeEach. It merges the gardenet configuration with the configuration from flags and creates the seed client
func (*GardenletFramework) CreateInstallation ¶
func (f *GardenletFramework) CreateInstallation(ctx context.Context) (*landscaperv1alpha1.Installation, error)
CreateInstallation creates an Installation CRD in the landscaper cluster
func (*GardenletFramework) CreateInstallationImports ¶
func (f *GardenletFramework) CreateInstallationImports(ctx context.Context) error
CreateInstallationImports creates minimal import resources required or the Gardenlet landscaper - two targets - config map landscaper configuration - config map image vector override - config map components image vector override
func (*GardenletFramework) DeleteInstallationResources ¶
func (f *GardenletFramework) DeleteInstallationResources(ctx context.Context) error
DeleteInstallationResources deletes the previously created landscaper resources
type LandscaperCommonConfig ¶
type LandscaperCommonConfig struct { KubeconfigPathLandscaperCluster string TargetNamespace string ComponentConfig ComponentConfig }
LandscaperCommonConfig is the configuration for the landscaper
func RegisterLandscaperCommonFrameworkFlags ¶
func RegisterLandscaperCommonFrameworkFlags() *LandscaperCommonConfig
RegisterLandscaperCommonFrameworkFlags adds all flags that are needed to configure a landscaper common framework to the provided flagset.