Skip to content

Commit

Permalink
cmd/compile/internal/syntax: don't depend on hardwired $GOROOT name
Browse files Browse the repository at this point in the history
Fixes #17697.

Change-Id: I3c47e139b09bde81566e29a1ac0ec8c58d55a34a
Reviewed-on: https://go-review.googlesource.com/32539
Run-TryBot: Robert Griesemer <[email protected]>
Reviewed-by: Matthew Dempsky <[email protected]>
TryBot-Result: Gobot Gobot <[email protected]>
  • Loading branch information
griesemer committed Nov 1, 2016
1 parent 7c7349c commit 012fec3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/cmd/compile/internal/syntax/parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ func TestStdLib(t *testing.T) {
defer close(results)
for _, dir := range []string{
runtime.GOROOT(),
//"/Users/gri/src",
} {
walkDirs(t, dir, func(filename string) {
if debug {
Expand Down Expand Up @@ -100,7 +99,7 @@ func walkDirs(t *testing.T, dir string, action func(string)) {
}
} else if fi.IsDir() && fi.Name() != "testdata" {
path := filepath.Join(dir, fi.Name())
if !strings.Contains(path, "go/test") {
if !strings.HasSuffix(path, "/test") {
dirs = append(dirs, path)
}
}
Expand Down

0 comments on commit 012fec3

Please sign in to comment.