testutils

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StoragePut    = "Put"
	StorageGet    = "Get"
	StorageGetAll = "GetAll"
	StorageDelete = "Delete"
)

Method names for MockStorage

Variables

This section is empty.

Functions

This section is empty.

Types

type FakeRunner

type FakeRunner struct {
	Err error
}

func (*FakeRunner) Run

func (f *FakeRunner) Run(command *runner.Command) error

type MockStorage

type MockStorage struct {
	mock.Mock
}

MockStorage is a reusable mock of storage.Interface

func (*MockStorage) Delete

func (m *MockStorage) Delete(ctx context.Context, prefix string, key string) error

func (*MockStorage) Get

func (m *MockStorage) Get(ctx context.Context, prefix string, key string) ([]byte, error)

func (*MockStorage) GetAll

func (m *MockStorage) GetAll(ctx context.Context, prefix string) ([][]byte, error)

func (*MockStorage) Put

func (m *MockStorage) Put(ctx context.Context, prefix string, key string, value []byte) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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