Close resources in TestLeasedKv

This commit is contained in:
Kuba Podgórski 2021-03-06 12:03:57 +01:00
parent ab50403c35
commit 7b005f69c6

View file

@ -44,8 +44,12 @@ func TestLeasedKv(t *testing.T) {
if err != nil {
t.Fatal(err)
}
cli := v3client.New(etcd.Server)
defer func() {
etcd.Close()
<-etcd.Server.StopNotify()
cli.Close()
}()
lkv := newLeasedKV(cli, "/test", 1)