update for latest protoc-gen-micro

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
2021-05-08 12:45:08 +03:00
parent e3c6288803
commit b9491f0a24
11 changed files with 258 additions and 101 deletions

View File

@@ -44,8 +44,9 @@ func RegisterTestServer(s server.Server, sh TestServer, opts ...server.HandlerOp
test
}
h := &testServer{sh}
var nopts []server.HandlerOption
for _, endpoint := range NewTestEndpoints() {
opts = append(opts, api.WithEndpoint(endpoint))
nopts = append(nopts, api.WithEndpoint(endpoint))
}
return s.Handle(s.NewHandler(&Test{h}, opts...))
return s.Handle(s.NewHandler(&Test{h}, append(nopts, opts...)...))
}