helpers

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BrokerTracingTestHelper added in v0.10.0

func BrokerTracingTestHelper(t *testing.T, brokerClass string, channel metav1.TypeMeta, setupClient lib.SetupClientOption)

BrokerTracingTestHelper runs the Broker tracing test using the given TypeMeta.

func BrokerTracingTestHelperWithChannelTestRunner added in v0.10.0

func BrokerTracingTestHelperWithChannelTestRunner(
	t *testing.T,
	brokerClass string,
	channelTestRunner lib.ChannelTestRunner,
	setupClient lib.SetupClientOption,
)

BrokerTracingTestHelperWithChannelTestRunner runs the Broker tracing tests for all Channels in the ChannelTestRunner.

func ChannelTracingTestHelper added in v0.10.0

func ChannelTracingTestHelper(t *testing.T, channel metav1.TypeMeta, setupClient lib.SetupClientOption)

ChannelTracingTestHelper runs the Channel tracing test using the given TypeMeta.

func ChannelTracingTestHelperWithChannelTestRunner added in v0.10.0

func ChannelTracingTestHelperWithChannelTestRunner(
	t *testing.T,
	channelTestRunner lib.ChannelTestRunner,
	setupClient lib.SetupClientOption,
)

ChannelTracingTestHelperWithChannelTestRunner runs the Channel tracing tests for all Channels in the ChannelTestRunner.

func SingleEventHelperForChannelTestHelper

func SingleEventHelperForChannelTestHelper(t *testing.T, encoding string,
	channelTestRunner lib.ChannelTestRunner,
	options ...lib.SetupClientOption,
)

SingleEventHelperForChannelTestHelper is the helper function for header_test

Types

type SetupInfrastructureFunc added in v0.10.0

type SetupInfrastructureFunc func(
	t *testing.T,
	channel *metav1.TypeMeta,
	client *lib.Client,
	loggerPodName string,
	tc TracingTestCase,
) (tracinghelper.TestSpanTree, lib.EventMatchFunc)

SetupInfrastructureFunc sets up the infrastructure for running tracing tests. It returns the expected trace as well as a string that is expected to be in the logger Pod's logs.

type TracingTestCase added in v0.10.0

type TracingTestCase struct {
	// IncomingTraceId controls whether the original request is sent to the Broker/Channel already
	// has a trace ID associated with it by the sender.
	IncomingTraceId bool
	// Istio controls whether the Pods being created for the test (sender, transformer, logger,
	// etc.) have Istio sidecars. It does not affect the Channel Pods.
	Istio bool
}

TracingTestCase is the test case information for tracing tests.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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