stubs

package
v1.6.8 Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2017 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package stubs implements a stub for the EtcdKeysAPI, used primarily for unit testing purposes

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EtcdKeysAPI

type EtcdKeysAPI interface {
	Set(context context.Context, key, value string, options *etcd.SetOptions) (*etcd.Response, error)
	Get(context context.Context, key string, options *etcd.GetOptions) (*etcd.Response, error)
	Delete(context context.Context, key string, options *etcd.DeleteOptions) (*etcd.Response, error)
}

type EtcdKeysAPIStub

type EtcdKeysAPIStub struct {
	// contains filtered or unexported fields
}

func NewEtcdKeysAPIStub

func NewEtcdKeysAPIStub() *EtcdKeysAPIStub

NewEtcdKeysAPIStub returns an initialized EtcdKeysAPIStub

func (*EtcdKeysAPIStub) Delete

func (ec *EtcdKeysAPIStub) Delete(context context.Context, key string, options *etcd.DeleteOptions) (*etcd.Response, error)

func (*EtcdKeysAPIStub) Get

func (ec *EtcdKeysAPIStub) Get(context context.Context, key string, options *etcd.GetOptions) (*etcd.Response, error)

func (*EtcdKeysAPIStub) GetAll

func (ec *EtcdKeysAPIStub) GetAll(key string) map[string]string

func (*EtcdKeysAPIStub) Set

func (ec *EtcdKeysAPIStub) Set(context context.Context, key, value string, options *etcd.SetOptions) (*etcd.Response, error)

Jump to

Keyboard shortcuts

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