veyron2/ipc: 3 of n. 'Invoker and Signature' rationalisation.
- implement the changed ipc.Serve signature
- transition all code to use it and ipc.ServeDispatcher
- get rid of the ugliness around calling Serve multiple
times to publish under multiple names in the mount table
and instead provide AddName/RemoveName methods.
Change-Id: Ic5edd709d28e2670369986a5b0fce4cd22e3cafd
diff --git a/tools/profile/impl_test.go b/tools/profile/impl_test.go
index 0bfd27e..dd8a329 100644
--- a/tools/profile/impl_test.go
+++ b/tools/profile/impl_test.go
@@ -85,7 +85,6 @@
}
func startServer(t *testing.T, r veyron2.Runtime) (ipc.Server, naming.Endpoint, error) {
- dispatcher := NewDispatcher()
server, err := r.NewServer()
if err != nil {
t.Errorf("NewServer failed: %v", err)
@@ -96,8 +95,8 @@
t.Errorf("Listen failed: %v", err)
return nil, nil, err
}
- if err := server.Serve("", dispatcher); err != nil {
- t.Errorf("Serve failed: %v", err)
+ if err := server.ServeDispatcher("", NewDispatcher()); err != nil {
+ t.Errorf("ServeDispatcher failed: %v", err)
return nil, nil, err
}
return server, endpoint, nil