Skip to content

Commit

Permalink
tests: fix windows test
Browse files Browse the repository at this point in the history
  • Loading branch information
cristianoliveira committed Oct 8, 2017
1 parent 3442548 commit e2a678a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/ergo_run_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"io/ioutil"
"log"
"net/http"
"os"
"os/exec"
"path/filepath"
"runtime"
Expand Down Expand Up @@ -435,11 +436,12 @@ func TestRunWindows(t *testing.T) {

cmd := ergo("run")
defer func() {
if cmd == nil || cmd.ProcessState == nil {
if cmd == nil {
os.Exit(1)
return
}

if !cmd.ProcessState.Exited() {
if cmd.Process != nil {
cmd.Process.Kill()
}
}()
Expand Down

0 comments on commit e2a678a

Please sign in to comment.