Merge pull request #4921 from mikedanese/too-many-gets

Interactions with etcd should optionally take a value that is filled with the result
This commit is contained in:
Clayton Coleman
2015-03-04 14:18:12 -05:00
12 changed files with 127 additions and 91 deletions

View File

@@ -60,7 +60,7 @@ func TestSetObj(t *testing.T) {
helper := tools.EtcdHelper{Client: client, Codec: stringCodec{}}
withEtcdKey(func(key string) {
fakeObject := fakeAPIObject("object")
if err := helper.SetObj(key, &fakeObject, 0 /* ttl */); err != nil {
if err := helper.SetObj(key, &fakeObject, nil, 0); err != nil {
t.Fatalf("unexpected error: %v", err)
}
resp, err := client.Get(key, false, false)