Skip to content

Commit 91170d7

Browse files
royeobradfitz
authored andcommitted
log: make the name of error clearer
Change-Id: Id0398b51336cc74f2172d9b8e18cb1dcb520b9a0 GitHub-Last-Rev: b5cf80b GitHub-Pull-Request: #29931 Reviewed-on: https://go-review.googlesource.com/c/go/+/159537 Reviewed-by: Emmanuel Odeke <[email protected]> Reviewed-by: Brad Fitzpatrick <[email protected]> Run-TryBot: Emmanuel Odeke <[email protected]> TryBot-Result: Gobot Gobot <[email protected]>
1 parent 4e2b0dd commit 91170d7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/log/log_test.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,9 @@ func testPrint(t *testing.T, flag int, prefix string, pattern string, useFormat
6161
line := buf.String()
6262
line = line[0 : len(line)-1]
6363
pattern = "^" + pattern + "hello 23 world$"
64-
matched, err4 := regexp.MatchString(pattern, line)
65-
if err4 != nil {
66-
t.Fatal("pattern did not compile:", err4)
64+
matched, err := regexp.MatchString(pattern, line)
65+
if err != nil {
66+
t.Fatal("pattern did not compile:", err)
6767
}
6868
if !matched {
6969
t.Errorf("log output should match %q is %q", pattern, line)

0 commit comments

Comments
 (0)