Skip to content

Commit

Permalink
e2e: fix -tags cov builds
Browse files Browse the repository at this point in the history
Wasn't compiling.
  • Loading branch information
Anthony Romano committed Feb 24, 2017
1 parent df3bb33 commit 2ec8572
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions e2e/etcd_spawn_cov.go.go → e2e/etcd_spawn_cov.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,16 @@ func spawnCmd(args []string) (*expect.ExpectProcess, error) {
fmt.Sprintf("-test.coverprofile=e2e.%v.coverprofile", time.Now().UnixNano()),
"-test.outputdir=" + coverPath,
}
ep := expect.NewExpectWithEnv(binDir+"/etcd_test", covArgs, args2env(args[1:]))
ep, err := expect.NewExpectWithEnv(binDir+"/etcd_test", covArgs, args2env(args[1:]))
if err != nil {
return nil, err
}
// ep sends SIGTERM to etcd_test process on ep.close()
// allowing the process to exit gracefully in order to generate a coverage report.
// note: go runtime ignores SIGINT but not SIGTERM
// if e2e test is run as a background process.
ep.StopSignal = syscall.SIGTERM
return nil, ep
return ep, nil
}
return expect.NewExpect(args[0], args[1:]...)
}
Expand Down

0 comments on commit 2ec8572

Please sign in to comment.