mocks

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2017 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	MachineReturn   []db.Machine
	ContainerReturn []db.Container
	EtcdReturn      []db.Etcd
	ClusterReturn   []db.Cluster
	HostReturn      string
	DeployArg       string

	MachineErr, ContainerErr, EtcdErr, ClusterErr, HostErr error
	DeployErr, ConnectionErr                               error
}

Client implements a mocked version of a Quilt client.

func (*Client) Close

func (c *Client) Close() error

Close the grpc connection.

func (*Client) Deploy

func (c *Client) Deploy(depl string) error

Deploy makes a request to the Quilt daemon to deploy the given deployment.

func (*Client) Host

func (c *Client) Host() string

Host returns the server address the Client is connected to.

func (*Client) QueryClusters

func (c *Client) QueryClusters() ([]db.Cluster, error)

QueryClusters retrieves cluster information tracked by the Quilt daemon.

func (*Client) QueryConnections

func (c *Client) QueryConnections() ([]db.Connection, error)

QueryConnections retrieves the connection information tracked by the Quilt daemon.

func (*Client) QueryContainers

func (c *Client) QueryContainers() ([]db.Container, error)

QueryContainers retrieves the containers tracked by the Quilt daemon.

func (*Client) QueryEtcd

func (c *Client) QueryEtcd() ([]db.Etcd, error)

QueryEtcd retrieves the etcd information tracked by the Quilt daemon.

func (*Client) QueryLabels

func (c *Client) QueryLabels() ([]db.Label, error)

QueryLabels retrieves the label information tracked by the Quilt daemon.

func (*Client) QueryMachines

func (c *Client) QueryMachines() ([]db.Machine, error)

QueryMachines retrieves the machines tracked by the Quilt daemon.

type Getter

type Getter struct {
	mock.Mock
}

Getter is an autogenerated mock type for the Getter type

func (*Getter) Client

func (_m *Getter) Client(_a0 string) (client.Client, error)

Client provides a mock function with given fields: _a0

func (*Getter) ContainerClient

func (_m *Getter) ContainerClient(_a0 client.Client, _a1 string) (client.Client, error)

ContainerClient provides a mock function with given fields: _a0, _a1

func (*Getter) LeaderClient

func (_m *Getter) LeaderClient(_a0 client.Client) (client.Client, error)

LeaderClient provides a mock function with given fields: _a0

Jump to

Keyboard shortcuts

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