sut

package
v0.39.6 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: Apache-2.0 Imports: 12 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Broker

type Broker struct {
	Name string
	Opts []resources.BrokerOption
}

Broker will hold settings for broker itself

type BrokerAndTriggers

type BrokerAndTriggers struct {
	Broker
	Triggers
}

BrokerAndTriggers will deploy a default broker and 2 triggers to route two types of events to receiver.

func (*BrokerAndTriggers) Deploy

func (b *BrokerAndTriggers) Deploy(ctx Context, dest duckv1.Destination) interface{}

type Context

type Context struct {
	Ctx context.Context
	Log *zap.SugaredLogger
	*testlib.Client
}

Context represents a context of system under test that we'd like to deploy and teardown.

type HasTeardown

type HasTeardown interface {
	// Teardown will remove all deployed SUT resources.
	Teardown(ctx Context)
}

HasTeardown indicates that SystemUnderTest supports custom teardown that exceeds regular teardown via usage of testlib.Tracker.

type SystemUnderTest

type SystemUnderTest interface {
	// Deploy is responsible for deploying SUT and returning a URL to feed
	// events into.
	Deploy(ctx Context, destination duckv1.Destination) interface{}
}

SystemUnderTest (SUT) represents a system that we'd like to test with continual prober.

func NewBrokerAndTriggers

func NewBrokerAndTriggers() SystemUnderTest

NewBrokerAndTriggers will create default configuration for BrokerAndTriggers based SUT.

func NewDefault

func NewDefault() SystemUnderTest

NewDefault will return a default SUT for this repo.

type Triggers

type Triggers struct {
	Types []string
}

Triggers will hold settings for triggers

Jump to

Keyboard shortcuts

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