Skip to content

Commit 28d389e

Browse files
ianlancetaylorgopherbot
authored andcommitted
internal/godebug: check error from os.ReadFile in test
Change-Id: I4770443c8eaa12add2e04cbf9d18ebfbbd851162 Reviewed-on: https://go-review.googlesource.com/c/go/+/643259 Reviewed-by: Michael Pratt <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Auto-Submit: Ian Lance Taylor <[email protected]> Commit-Queue: Ian Lance Taylor <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]>
1 parent 8071f2a commit 28d389e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/internal/godebug/godebug_test.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,9 @@ func TestCmdBisect(t *testing.T) {
109109

110110
var want []string
111111
src, err := os.ReadFile("godebug_test.go")
112+
if err != nil {
113+
t.Fatal(err)
114+
}
112115
for i, line := range strings.Split(string(src), "\n") {
113116
if strings.Contains(line, "BISECT"+" "+"BUG") {
114117
want = append(want, fmt.Sprintf("godebug_test.go:%d", i+1))

0 commit comments

Comments
 (0)