etcdtest

package
v0.4.0-beta3 Latest Latest
Warning

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

Go to latest
Published: May 20, 2014 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Copyright (c) 2013 Kelsey Hightower. All rights reserved. Use of this source code is governed by the Apache License, Version 2.0 that can be found in the LICENSE file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Responses map[string]*etcd.Response
}

Client represents a fake etcd client. Used for testing.

func NewClient

func NewClient() *Client

NewClient returns a fake etcd client.

func (*Client) AddResponse

func (c *Client) AddResponse(key string, response *etcd.Response)

AddResponses adds or updates the Client.Responses map.

func (*Client) Get

func (c *Client) Get(key string, sort, recurse bool) (*etcd.Response, error)

Get mimics the etcd.Client.Get() method.

Jump to

Keyboard shortcuts

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