Documentation
¶
Index ¶
- Constants
- Variables
- func GenerateKafkaConsumer(ctx context.Context) (*kafka.ConsumerGroup, error)
- func GetFailingMongo(ctx context.Context, cfg *config.Config, g service.Generator) (service.Datastore, error)
- func GetWorkingMongo(ctx context.Context, cfg *config.Config, g service.Generator) (service.Datastore, error)
- type Component
Constants ¶
View Source
const ( ComponentTestGroup = "test-consumer-group" DrainTopicTimeout = 10 * time.Second // maximum time to wait for a topic to be drained DrainTopicMaxMessages = 1000 // maximum number of messages that will be drained from a topic MinioCheckRetries = 3 // maximum number of retires to validate that a file is present in minio WaitEventTimeout = 10 * time.Second // maximum time that the component test consumer will wait for a )
Variables ¶
View Source
var ( BuildTime string = "1625046891" GitCommit string = "7434fe334d9f51b7239f978094ea29d10ac33b16" Version string = "" )
Functions ¶
func GenerateKafkaConsumer ¶ added in v1.2.0
func GenerateKafkaConsumer(ctx context.Context) (*kafka.ConsumerGroup, error)
GenerateKafkaConsumer produces a consumer for specific steps. Currently only for PUT filters/{id}/submit
Types ¶
type Component ¶
type Component struct { componenttest.ErrorFeature ApiFeature *componenttest.APIFeature DatasetAPI *httpfake.HTTPFake CantabularClient *mock.CantabularClient HTTPServer *http.Server // contains filtered or unexported fields }
func NewComponent ¶
func (*Component) Close ¶
func (c *Component) Close()
Close kills the application under test, and then it shuts down the testing producer.
func (*Component) Init ¶
Init initialises the server, the mocks and waits for the dependencies to be ready
func (*Component) MongoDatastoreFailsForUpdateFilterOutput ¶
func (*Component) MongoDatastoreIsFailing ¶ added in v1.2.0
func (*Component) RegisterSteps ¶
func (c *Component) RegisterSteps(ctx *godog.ScenarioContext)
Click to show internal directories.
Click to hide internal directories.