mocks

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CamundaServer

func CamundaServer(ctx context.Context, wg *sync.WaitGroup) (url string, requests chan Request)

func CamundaServerWithResponse

func CamundaServerWithResponse(ctx context.Context, wg *sync.WaitGroup, resp interface{}) (url string, requests chan Request)

Types

type KafkaMock

type KafkaMock struct {
	Produced map[string][]string
	// contains filtered or unexported fields
}

func Kafka

func Kafka() *KafkaMock

func (*KafkaMock) Close

func (this *KafkaMock) Close()

func (*KafkaMock) Consume

func (this *KafkaMock) Consume(topic string, listener func(msg []byte) error) (err error)

func (*KafkaMock) EnsureTopic

func (this *KafkaMock) EnsureTopic(bootstrapUrl string, topic string, config map[string]string) (err error)

func (*KafkaMock) GetProduced

func (this *KafkaMock) GetProduced(topic string) []string

func (*KafkaMock) NewProducer

func (this *KafkaMock) NewProducer()

func (*KafkaMock) Produce

func (this *KafkaMock) Produce(topic string, message string)

func (*KafkaMock) ProduceWithKey

func (this *KafkaMock) ProduceWithKey(topic string, key string, message string)

func (*KafkaMock) Publish

func (this *KafkaMock) Publish(topic string, key string, message []byte) error

func (*KafkaMock) Stop

func (this *KafkaMock) Stop()

func (*KafkaMock) Subscribe

func (this *KafkaMock) Subscribe(topic string, listener func(msg string) error)

type Request

type Request struct {
	Url     string
	Payload []byte
	Err     error
}

Jump to

Keyboard shortcuts

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