Deprecate and remove service stop API. (#3578)

Fixes #3570
This commit is contained in:
Harshavardhana
2017-01-14 14:48:52 -08:00
committed by GitHub
parent 2959c104b3
commit caecd75a2a
10 changed files with 5 additions and 156 deletions

View File

@@ -47,17 +47,13 @@ func testAdminCmd(cmd cmdType, t *testing.T) {
}
go func() {
// mocking signal receiver
// A test signal receiver
<-globalServiceSignalCh
}()
ga := AuthRPCArgs{AuthToken: reply.AuthToken, RequestTime: time.Now().UTC()}
genReply := AuthRPCReply{}
switch cmd {
case stopCmd:
if err = adminServer.Shutdown(&ga, &genReply); err != nil {
t.Errorf("stopCmd: Expected: <nil>, got: %v", err)
}
case restartCmd:
if err = adminServer.Restart(&ga, &genReply); err != nil {
t.Errorf("restartCmd: Expected: <nil>, got: %v", err)
@@ -65,10 +61,6 @@ func testAdminCmd(cmd cmdType, t *testing.T) {
}
}
func TestAdminShutdown(t *testing.T) {
testAdminCmd(stopCmd, t)
}
func TestAdminRestart(t *testing.T) {
testAdminCmd(restartCmd, t)
}