integration/fixtures: Move the 'tests/integration/fixtures' directory up and update references.

I moved the files up as they are shared between e2e & integrational tests.
This commit is contained in:
Piotr Tabor
2020-10-07 15:38:28 +02:00
parent bb9703820c
commit be4e8b7013
76 changed files with 86 additions and 79 deletions

View File

@@ -24,6 +24,7 @@ import (
"go.etcd.io/etcd/tests/v3/integration"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/proxy/grpcproxy"
"go.uber.org/zap"
"google.golang.org/grpc"
@@ -114,8 +115,8 @@ func newClusterProxyServer(lg *zap.Logger, endpoints []string, t *testing.T) *cl
cts.server.Serve(cts.l)
}()
Register(lg, client, "test-prefix", cts.l.Addr().String(), 7)
cts.cp, cts.donec = NewClusterProxy(lg, client, cts.l.Addr().String(), "test-prefix")
grpcproxy.Register(lg, client, "test-prefix", cts.l.Addr().String(), 7)
cts.cp, cts.donec = grpcproxy.NewClusterProxy(lg, client, cts.l.Addr().String(), "test-prefix")
cts.caddr = cts.l.Addr().String()
pb.RegisterClusterServer(cts.server, cts.cp)
close(servec)

View File

@@ -24,6 +24,7 @@ import (
"go.etcd.io/etcd/tests/v3/integration"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/proxy/grpcproxy"
"google.golang.org/grpc"
)
@@ -76,7 +77,7 @@ func newKVProxyServer(endpoints []string, t *testing.T) *kvproxyTestServer {
t.Fatal(err)
}
kvp, _ := NewKvProxy(client)
kvp, _ := grpcproxy.NewKvProxy(client)
kvts := &kvproxyTestServer{
kp: kvp,

View File

@@ -22,6 +22,7 @@ import (
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/naming"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/proxy/grpcproxy"
"go.uber.org/zap"
gnaming "google.golang.org/grpc/naming"
@@ -45,7 +46,7 @@ func TestRegister(t *testing.T) {
t.Fatalf("len(ups) expected 0, got %d (%v)", len(ups), ups)
}
donec := Register(zap.NewExample(), cli, testPrefix, paddr, 5)
donec := grpcproxy.Register(zap.NewExample(), cli, testPrefix, paddr, 5)
ups, err = wa.Next()
if err != nil {