From 6f7cabf779152ab452bec3e7d10291383b6437e5 Mon Sep 17 00:00:00 2001 From: rigelrozanski Date: Thu, 31 May 2018 14:59:03 -0700 Subject: [PATCH] fix tests/process.go lint --- tests/process.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/process.go b/tests/process.go index fcc6e3e0ea..d2459a0b5b 100644 --- a/tests/process.go +++ b/tests/process.go @@ -8,6 +8,7 @@ import ( "time" ) +// execution process type Process struct { ExecPath string Args []string @@ -94,16 +95,16 @@ func StartProcess(dir string, name string, args []string, outFile, errFile io.Wr return proc, nil } +// stop the process func (proc *Process) Stop(kill bool) error { if kill { // fmt.Printf("Killing process %v\n", proc.Cmd.Process) return proc.Cmd.Process.Kill() - } else { - // fmt.Printf("Stopping process %v\n", proc.Cmd.Process) - return proc.Cmd.Process.Signal(os.Interrupt) } + return proc.Cmd.Process.Signal(os.Interrupt) } +// wait for the process func (proc *Process) Wait() { <-proc.WaitCh }