Skip to content

Commit

Permalink
message/pipeline: skip test if the 'go' executable is not found
Browse files Browse the repository at this point in the history
Fixes #32844

Change-Id: I9d5364df4f827db4de3c144a565c1d05d8a181bd
Reviewed-on: https://go-review.googlesource.com/c/text/+/192325
Run-TryBot: Bryan C. Mills <[email protected]>
TryBot-Result: Gobot Gobot <[email protected]>
Reviewed-by: Alexander Rakoczy <[email protected]>
  • Loading branch information
Bryan C. Mills committed Aug 29, 2019
1 parent 4bf50aa commit 3d0f797
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions message/pipeline/pipeline_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import (
"fmt"
"io/ioutil"
"os"
"os/exec"
"path"
"path/filepath"
"runtime"
Expand All @@ -30,6 +31,10 @@ func TestFullCycle(t *testing.T) {
if runtime.GOOS == "android" {
t.Skip("cannot load outside packages on android")
}
if _, err := exec.LookPath("go"); err != nil {
t.Skipf("skipping because 'go' command is unavailable: %v", err)
}

const path = "./testdata"
dirs, err := ioutil.ReadDir(path)
if err != nil {
Expand Down

0 comments on commit 3d0f797

Please sign in to comment.