Skip to content

Commit

Permalink
Makefile: reduce test timeout when TRAVIS==true
Browse files Browse the repository at this point in the history
Reduces test timeout by one minute so that Go will timeout before
Travis-CI and report useful informations about the hang.
  • Loading branch information
aarzilli authored and derekparker committed Apr 17, 2020
1 parent 682ee7f commit 55543e2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions _scripts/make.go
Expand Up @@ -278,6 +278,9 @@ func testFlags() []string {
}
if NOTimeout {
testFlags = append(testFlags, "-timeout", "0")
} else if os.Getenv("TRAVIS") == "true" {
// Make test timeout shorter than Travis' own timeout so that Go can report which test hangs.
testFlags = append(testFlags, "-timeout", "9m")
}
if runtime.GOOS == "darwin" {
testFlags = append(testFlags, "-exec="+wd+"/_scripts/testsign")
Expand Down

0 comments on commit 55543e2

Please sign in to comment.