Help us shape the future of Go! Take the 2026 Go Developer Survey

v2

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockStreamDefinitionBuilder

type MockStreamDefinitionBuilder struct {
	// contains filtered or unexported fields
}

MockStreamDefinitionBuilder provides a fluent builder for constructing *testv2.MockStreamDefinition objects in tests.

func NewMockStreamDefinitionLayoutV1Builder added in v1.1.10

func NewMockStreamDefinitionLayoutV1Builder(objectName types.NamespacedName) *MockStreamDefinitionBuilder

NewMockStreamDefinitionLayoutV1Builder creates a new builder pre-populated with the same defaults used by SetupClient.

func NewMockStreamDefinitionLayoutV2Builder added in v1.1.10

func NewMockStreamDefinitionLayoutV2Builder(objectName types.NamespacedName) *MockStreamDefinitionBuilder

NewMockStreamDefinitionLayoutV2Builder creates a new builder pre-populated with the same defaults used by SetupClient.

func (*MockStreamDefinitionBuilder) Apply

Apply runs an arbitrary mutation function on the underlying definition. This allows composing the builder with the existing functional-option style helpers in this package.

func (*MockStreamDefinitionBuilder) Build

Build returns the constructed *testv2.MockStreamDefinition. The result is computed on the first call and the same pointer is returned on subsequent calls.

func (*MockStreamDefinitionBuilder) WithMigrationJobTemplateRef added in v1.2.0

func (b *MockStreamDefinitionBuilder) WithMigrationJobTemplateRef(name types.NamespacedName) *MockStreamDefinitionBuilder

WithMigrationJobTemplateRef sets the job template reference for the batch job backend, initializing the batch job backend if it is currently nil.

func (*MockStreamDefinitionBuilder) WithName

WithName sets the name and namespace of the stream definition.

func (*MockStreamDefinitionBuilder) WithNoBackend added in v1.1.4

WithNoBackend configures the stream definition with an empty backend, clearing both the batch job and cron job backends.

func (*MockStreamDefinitionBuilder) WithPhase

WithPhase sets the status phase of the stream definition.

func (*MockStreamDefinitionBuilder) WithSchedule

WithSchedule configures the stream definition with a cron job backend using the provided schedule, clearing the batch job backend.

func (*MockStreamDefinitionBuilder) WithScheduledJobTemplateRef added in v1.1.7

func (b *MockStreamDefinitionBuilder) WithScheduledJobTemplateRef(name types.NamespacedName) *MockStreamDefinitionBuilder

WithScheduledJobTemplateRef sets the job template reference for the batch job backend, initializing the batch job backend if it is currently nil.

func (*MockStreamDefinitionBuilder) WithStreamingJobTemplateRef added in v1.1.7

func (b *MockStreamDefinitionBuilder) WithStreamingJobTemplateRef(name types.NamespacedName) *MockStreamDefinitionBuilder

WithStreamingJobTemplateRef sets the job template reference for the batch job backend, initializing the batch job backend if it is currently nil.

func (*MockStreamDefinitionBuilder) WithSuspendedSpec

func (b *MockStreamDefinitionBuilder) WithSuspendedSpec(spec bool) *MockStreamDefinitionBuilder

WithSuspendedSpec sets the Suspended flag on the execution settings.

func (*MockStreamDefinitionBuilder) WithV1BackfillJobTemplateRef added in v1.1.10

func (b *MockStreamDefinitionBuilder) WithV1BackfillJobTemplateRef(name types.NamespacedName) *MockStreamDefinitionBuilder

WithV1BackfillJobTemplateRef sets the job template reference for the batch job backend, initializing the batch job backend if it is currently nil.

func (*MockStreamDefinitionBuilder) WithV2BackfillJobTemplateRef added in v1.1.10

func (b *MockStreamDefinitionBuilder) WithV2BackfillJobTemplateRef(name types.NamespacedName) *MockStreamDefinitionBuilder

WithV2BackfillJobTemplateRef sets the job template reference for the batch job backend, initializing the batch job backend if it is currently nil.

Jump to

Keyboard shortcuts

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