provider

package
v0.0.0-...-b93a6bd Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package provider defines interface for obtaining instances of objects that we commonly use in all the modules. This pattern is useful to make our modules more flexible, as they don't take concrete objects but interfaces, which can be mocked, replaced, etc.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Client(cbtest.T) *cb.DevClient
	ClientE(cbtest.T) (*cb.DevClient, error)
}

Client provides a *cb.DevClient instance. Note that this is an operation that can fail, therefore, we have a function that panics and another one that returns the error.

type Config

type Config interface {
	Config(cbtest.T) *c.Config
}

Config provides a *config.Config instance.

type ConfigAndClient

type ConfigAndClient interface {
	Config
	Client
}

ConfigAndClient provides both provider.Config and provider.Client.

Jump to

Keyboard shortcuts

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