client: Allow setting zap logger in config

This commit is contained in:
Marek Siarkowicz
2021-05-11 16:02:37 +02:00
parent 7ae55cf981
commit 06afe87b34
11 changed files with 26 additions and 26 deletions

View File

@ -119,13 +119,13 @@ func testBalancerUnderNetworkPartition(t *testing.T, op func(*clientv3.Client, c
Endpoints: []string{eps[0]},
DialTimeout: 3 * time.Second,
DialOptions: []grpc.DialOption{grpc.WithBlock()},
Logger: zaptest.NewLogger(t).Named("client"),
}
cli, err := integration.NewClient(t, ccfg)
if err != nil {
t.Fatal(err)
}
defer cli.Close()
cli = cli.WithLogger(zaptest.NewLogger(t).Named("client"))
// wait for eps[0] to be pinned
clientv3test.MustWaitPinReady(t, cli)