test

package
v0.0.0-...-7801012 Latest Latest
Warning

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

Go to latest
Published: May 23, 2024 License: Apache-2.0 Imports: 32 Imported by: 1

Documentation

Index

Constants

View Source
const (
	SonataFlowGreetingsWithDataInputSchemaCR = "sonataflow.org_v1alpha08_sonataflow_greetings_datainput.yaml"
	SonataFlowGreetingsWithStaticResourcesCR = "sonataflow.org_v1alpha08_sonataflow-metainf.yaml"
	SonataFlowSimpleOpsYamlCR                = "sonataflow.org_v1alpha08_sonataflow-simpleops.yaml"
	SonataFlowVetWithEventCR                 = "sonataflow.org_v1alpha08_sonataflow_vet_event.yaml"
	SonataFlowGreetingsDataInputSchemaConfig = "v1_configmap_greetings_datainput.yaml"
	SonataFlowGreetingsStaticFilesConfig     = "v1_configmap_greetings_staticfiles.yaml"
)

Variables

This section is empty.

Functions

func GetBaseClusterPlatformInReadyPhase

func GetBaseClusterPlatformInReadyPhase(namespace string) *operatorapi.SonataFlowClusterPlatform

func GetBasePlatform

func GetBasePlatform() *operatorapi.SonataFlowPlatform

func GetBasePlatformInReadyPhase

func GetBasePlatformInReadyPhase(namespace string) *operatorapi.SonataFlowPlatform

func GetBasePlatformWithBaseImageInReadyPhase

func GetBasePlatformWithBaseImageInReadyPhase(namespace string) *operatorapi.SonataFlowPlatform

func GetBasePlatformWithDevBaseImageInReadyPhase

func GetBasePlatformWithDevBaseImageInReadyPhase(namespace string) *operatorapi.SonataFlowPlatform

func GetBaseSonataFlow

func GetBaseSonataFlow(namespace string) *operatorapi.SonataFlow

func GetBaseSonataFlowWithDevProfile

func GetBaseSonataFlowWithDevProfile(namespace string) *operatorapi.SonataFlow

func GetBaseSonataFlowWithProdOpsProfile

func GetBaseSonataFlowWithProdOpsProfile(namespace string) *operatorapi.SonataFlow

GetBaseSonataFlowWithProdOpsProfile gets a base workflow that has a pre-built image set in podTemplate.

func GetBaseSonataFlowWithProdProfile

func GetBaseSonataFlowWithProdProfile(namespace string) *operatorapi.SonataFlow

func GetKubernetesResource

func GetKubernetesResource(testFile string, resource client.Object)

func GetLocalSucceedSonataFlowBuild

func GetLocalSucceedSonataFlowBuild(name, namespace string) *operatorapi.SonataFlowBuild

GetLocalSucceedSonataFlowBuild gets a local (testdata dir ref to caller) SonataFlowBuild with Succeed status equals to true.

func GetNewEmptySonataFlowBuild

func GetNewEmptySonataFlowBuild(name, namespace string) *operatorapi.SonataFlowBuild

func GetPlatformMinikubeE2eTest

func GetPlatformMinikubeE2eTest() string

func GetPlatformOpenshiftE2eTest

func GetPlatformOpenshiftE2eTest() string

func GetSonataFlow

func GetSonataFlow(testFile, namespace string) *operatorapi.SonataFlow

func GetSonataFlowBuilderConfig

func GetSonataFlowBuilderConfig(namespace string) *corev1.ConfigMap

func GetSonataFlowClusterPlatformInReadyPhase

func GetSonataFlowClusterPlatformInReadyPhase(path string, namespace string) *operatorapi.SonataFlowClusterPlatform

func GetSonataFlowE2EPlatformNoServicesDirectory

func GetSonataFlowE2EPlatformNoServicesDirectory() string

func GetSonataFlowE2EPlatformPersistenceSampleDataDirectory

func GetSonataFlowE2EPlatformPersistenceSampleDataDirectory(subdir string) string

func GetSonataFlowE2EPlatformServicesDirectory

func GetSonataFlowE2EPlatformServicesDirectory() string

func GetSonataFlowE2EWorkflowPersistenceSampleDataDirectory

func GetSonataFlowE2EWorkflowPersistenceSampleDataDirectory(subdir string) string

func GetSonataFlowE2eOrderProcessingFolder

func GetSonataFlowE2eOrderProcessingFolder() string

func GetSonataFlowPlatformInReadyPhase

func GetSonataFlowPlatformInReadyPhase(path string, namespace string) *operatorapi.SonataFlowPlatform

func GetVetEventSonataFlow

func GetVetEventSonataFlow(namespace string) *operatorapi.SonataFlow

func MustGetConfigMap

func MustGetConfigMap(t *testing.T, client ctrl.WithWatch, workflow *operatorapi.SonataFlow) *v1.ConfigMap

func MustGetDeployment

func MustGetDeployment(t *testing.T, client ctrl.WithWatch, workflow *operatorapi.SonataFlow) *appsv1.Deployment

func MustGetService

func MustGetService(t *testing.T, client ctrl.WithWatch, workflow *operatorapi.SonataFlow) *v1.Service

func MustGetWorkflow

func MustGetWorkflow(t *testing.T, client ctrl.WithWatch, name types.NamespacedName) *operatorapi.SonataFlow

func NewFakeRecorder

func NewFakeRecorder() record.EventRecorder

func NewKogitoClientBuilderWithOpenShift

func NewKogitoClientBuilderWithOpenShift() *fake.ClientBuilder

NewKogitoClientBuilderWithOpenShift creates a new fake client with OpenShift schemas. If your object is not present, just add in the list below.

func NewSonataFlow

func NewSonataFlow(filePath string, namespace string, options ...func(*operatorapi.SonataFlow)) *operatorapi.SonataFlow

func NewSonataFlowClientBuilder

func NewSonataFlowClientBuilder() *fake.ClientBuilder

NewSonataFlowClientBuilder creates a new fake.ClientBuilder with the right scheme references

func SetDevProfile

func SetDevProfile(workflow *operatorapi.SonataFlow)

func SetPreviewProfile

func SetPreviewProfile(workflow *operatorapi.SonataFlow)

Types

type MockPlatformService

type MockPlatformService struct {
	Client clientv1.Client

	CreateFunc      func(ctx context.Context, obj clientv1.Object, opts ...clientv1.CreateOption) error
	DeleteFunc      func(ctx context.Context, obj clientv1.Object, opts ...clientv1.DeleteOption) error
	GetFunc         func(ctx context.Context, key clientv1.ObjectKey, obj clientv1.Object) error
	ListFunc        func(ctx context.Context, list clientv1.ObjectList, opts ...clientv1.ListOption) error
	UpdateFunc      func(ctx context.Context, obj clientv1.Object, opts ...clientv1.UpdateOption) error
	PatchFunc       func(ctx context.Context, obj clientv1.Object, patch clientv1.Patch, opts ...clientv1.PatchOption) error
	DeleteAllOfFunc func(ctx context.Context, obj clientv1.Object, opts ...clientv1.DeleteAllOfOption) error
	GetCachedFunc   func(ctx context.Context, key clientv1.ObjectKey, obj clientv1.Object) error
	GetSchemeFunc   func() *runtime.Scheme
	StatusFunc      func() clientv1.StatusWriter
	// contains filtered or unexported fields
}

func (*MockPlatformService) Create

func (service *MockPlatformService) Create(ctx context.Context, obj clientv1.Object, opts ...clientv1.CreateOption) error

func (*MockPlatformService) Delete

func (service *MockPlatformService) Delete(ctx context.Context, obj clientv1.Object, opts ...clientv1.DeleteOption) error

func (*MockPlatformService) DeleteAllOf

func (service *MockPlatformService) DeleteAllOf(ctx context.Context, obj clientv1.Object, opts ...clientv1.DeleteAllOfOption) error

func (*MockPlatformService) Get

func (*MockPlatformService) GetCached

func (service *MockPlatformService) GetCached(ctx context.Context, key clientv1.ObjectKey, obj clientv1.Object) error

func (*MockPlatformService) GetScheme

func (service *MockPlatformService) GetScheme() *runtime.Scheme

func (*MockPlatformService) IsMockService

func (service *MockPlatformService) IsMockService() bool

func (*MockPlatformService) List

func (service *MockPlatformService) List(ctx context.Context, list clientv1.ObjectList, opts ...clientv1.ListOption) error

func (*MockPlatformService) Patch

func (service *MockPlatformService) Patch(ctx context.Context, obj clientv1.Object, patch clientv1.Patch, opts ...clientv1.PatchOption) error

func (*MockPlatformService) Status

func (service *MockPlatformService) Status() clientv1.StatusWriter

func (*MockPlatformService) Update

func (service *MockPlatformService) Update(ctx context.Context, obj clientv1.Object, opts ...clientv1.UpdateOption) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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