From 5266b56f43f47cada37168d91eeee61367cd80a6 Mon Sep 17 00:00:00 2001 From: Jae Kwon Date: Sun, 21 Feb 2016 23:45:10 -0800 Subject: [PATCH] Conform to TMSP NewServer --- proxy/remote_app_conn_test.go | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/proxy/remote_app_conn_test.go b/proxy/remote_app_conn_test.go index a997cbfea..dcb4fdc16 100644 --- a/proxy/remote_app_conn_test.go +++ b/proxy/remote_app_conn_test.go @@ -13,10 +13,11 @@ func TestEcho(t *testing.T) { sockPath := Fmt("unix:///tmp/echo_%v.sock", RandStr(6)) // Start server - _, err := server.StartListener(sockPath, dummy.NewDummyApplication()) + s, err := server.NewServer(sockPath, dummy.NewDummyApplication()) if err != nil { Exit(err.Error()) } + defer s.Stop() // Start client proxy, err := NewRemoteAppConn(sockPath) if err != nil { @@ -35,10 +36,11 @@ func BenchmarkEcho(b *testing.B) { b.StopTimer() // Initialize sockPath := Fmt("unix:///tmp/echo_%v.sock", RandStr(6)) // Start server - _, err := server.StartListener(sockPath, dummy.NewDummyApplication()) + s, err := server.NewServer(sockPath, dummy.NewDummyApplication()) if err != nil { Exit(err.Error()) } + defer s.Stop() // Start client proxy, err := NewRemoteAppConn(sockPath) if err != nil { @@ -62,10 +64,11 @@ func BenchmarkEcho(b *testing.B) { func TestInfo(t *testing.T) { sockPath := Fmt("unix:///tmp/echo_%v.sock", RandStr(6)) // Start server - _, err := server.StartListener(sockPath, dummy.NewDummyApplication()) + s, err := server.NewServer(sockPath, dummy.NewDummyApplication()) if err != nil { Exit(err.Error()) } + defer s.Stop() // Start client proxy, err := NewRemoteAppConn(sockPath) if err != nil {