Documentation ¶
Index ¶
- Constants
- type Sample
- type Scenario
- func (s *Scenario) Apply(name string, objects []*unstructured.Unstructured)
- func (s *Scenario) ApplyInput()
- func (s *Scenario) ApplyManifests(name string, path ...string)
- func (s *Scenario) Cleanup()
- func (s *Scenario) CleanupInput()
- func (s *Scenario) CleanupIntermediateManifests()
- func (s *Scenario) CleanupOutput()
- func (s *Scenario) GatherLogs()
- func (s *Scenario) GetName() string
- func (s *Scenario) Setup()
- func (s *Scenario) Verify(name string, matchSpec bool, objects []*unstructured.Unstructured)
- func (s *Scenario) VerifyInput()
- func (s *Scenario) VerifyManifests(name string, matchSpec bool, path ...string)
- func (s *Scenario) VerifyOutputExists()
- func (s *Scenario) VerifyOutputSpecMatches()
Constants ¶
View Source
const ( // ExistTimeout - time in which object should exist after creation; ExistTimeout = 1 * time.Minute // InstantTimeout - time used to check properties that should already apply. // It isn't 0 to give checks time to run. InstantTimeout = 2 * time.Second // ReadyTimeout - time after creation that object should be available; ReadyTimeout = 4 * time.Minute // Composition Reconcile - bound on time CompositionReconcileTimeout = 4 * time.Minute // DeleteTimeout time to delete DeleteTimeout = 2 * time.Minute // OutputExistsTimeout - time in which output objects exist after reconcile OutputExistsTimeout = CompositionReconcileTimeout )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Scenario ¶
type Scenario struct { T *testing.T C *testclient.Client // contains filtered or unexported fields }
Scenario - context for each scenario
func NewBasic ¶
NewBasic - return a Scenario object for Basic testcases
- Use ../../tests/data/Test<name> for data
- Expect input.yaml, output.yaml (optional)
- Dont need KCC enabled for tests
func NewFromSample ¶
func NewFromSample(t *testing.T, sample Sample, dependentSamples []Sample, hasCloudRsrc bool) *Scenario
NewFromSample - return a Scenario object for testing Samples/
func (*Scenario) Apply ¶
func (s *Scenario) Apply(name string, objects []*unstructured.Unstructured)
func (*Scenario) ApplyInput ¶
func (s *Scenario) ApplyInput()
func (*Scenario) ApplyManifests ¶
func (*Scenario) CleanupInput ¶
func (s *Scenario) CleanupInput()
func (*Scenario) CleanupIntermediateManifests ¶
func (s *Scenario) CleanupIntermediateManifests()
func (*Scenario) CleanupOutput ¶
func (s *Scenario) CleanupOutput()
func (*Scenario) GatherLogs ¶
func (s *Scenario) GatherLogs()
GatherLogs - grab the logs for the test case
func (*Scenario) Verify ¶
func (s *Scenario) Verify(name string, matchSpec bool, objects []*unstructured.Unstructured)
func (*Scenario) VerifyInput ¶
func (s *Scenario) VerifyInput()
func (*Scenario) VerifyManifests ¶
func (*Scenario) VerifyOutputExists ¶
func (s *Scenario) VerifyOutputExists()
func (*Scenario) VerifyOutputSpecMatches ¶
func (s *Scenario) VerifyOutputSpecMatches()
Click to show internal directories.
Click to hide internal directories.