core: Remove the NewServer method of the Runtime interface.
This is part of the runtimeX migration.
Change-Id: I92bdf790991926a55cff7a4394fa3bc114682511
diff --git a/tools/profile/impl_test.go b/tools/profile/impl_test.go
index 6204301..30891d3 100644
--- a/tools/profile/impl_test.go
+++ b/tools/profile/impl_test.go
@@ -7,6 +7,7 @@
"testing"
"v.io/core/veyron2"
+ "v.io/core/veyron2/context"
"v.io/core/veyron2/ipc"
"v.io/core/veyron2/naming"
"v.io/core/veyron2/rt"
@@ -83,8 +84,8 @@
return repository.ProfileServer(&server{suffix: suffix}), nil, nil
}
-func startServer(t *testing.T, r veyron2.Runtime) (ipc.Server, naming.Endpoint, error) {
- server, err := r.NewServer()
+func startServer(t *testing.T, ctx *context.T) (ipc.Server, naming.Endpoint, error) {
+ server, err := veyron2.NewServer(ctx)
if err != nil {
t.Errorf("NewServer failed: %v", err)
return nil, nil, err
@@ -114,8 +115,9 @@
t.Fatalf("Unexpected error initializing runtime: %s", err)
}
defer runtime.Cleanup()
+ ctx := runtime.NewContext()
- server, endpoint, err := startServer(t, runtime)
+ server, endpoint, err := startServer(t, ctx)
if err != nil {
return
}