Documentation
¶
Index ¶
- func NewConsumer(options ...streamconfig.Option) (stream.Consumer, error)
- func NewProducer(options ...streamconfig.Option) (stream.Producer, error)
- func TestBuffer(tb testing.TB, v ...string) io.ReadWriteCloser
- func TestConsumer(tb testing.TB, r io.ReadCloser, options ...streamconfig.Option) (stream.Consumer, func())
- func TestProducer(tb testing.TB, w io.Writer, options ...streamconfig.Option) (stream.Producer, func())
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewConsumer ¶
func NewConsumer(options ...streamconfig.Option) (stream.Consumer, error)
NewConsumer returns a new standard stream consumer.
func NewProducer ¶
func NewProducer(options ...streamconfig.Option) (stream.Producer, error)
NewProducer returns a new standard stream producer.
func TestBuffer ¶
func TestBuffer(tb testing.TB, v ...string) io.ReadWriteCloser
TestBuffer returns an io.ReadWriter that can be used during testing. You can pass additional string arguments after the first argument. Each extra argument is written as a line to the buffer, delimited by \n.
func TestConsumer ¶
func TestConsumer(tb testing.TB, r io.ReadCloser, options ...streamconfig.Option) (stream.Consumer, func())
TestConsumer returns a new standardstream consumer to be used in test cases. You pass in an io.ReadCloser object as the second argument.
The return value is the consumer, and a function that should be deferred to clean up resources.
func TestProducer ¶
func TestProducer(tb testing.TB, w io.Writer, options ...streamconfig.Option) (stream.Producer, func())
TestProducer returns a new standardstream producer to be used in test cases. You pass in an io.Writer object as the second argument.
The return value is the producer, and a function that should be deferred to clean up resources.
Types ¶
This section is empty.