One too many lines was deleted, and it would print a header multiple times.
Add a test.
Change-Id: I4906b454dbb66193d515ffacf43849ffdc2dede6
Reviewed-on: https://go-review.googlesource.com/c/142937
Reviewed-by: Ralph Corderoy <ralph@inputplus.co.uk>
Reviewed-by: Daniel Martí <mvdan@mvdan.cc>
Run-TryBot: Daniel Martí <mvdan@mvdan.cc>
TryBot-Result: Gobot Gobot <gobot@golang.org>
failed = true
}
}
+ if bytes.Count(output, []byte("TYPES\n")) > 1 {
+ t.Fatalf("%s: repeating headers", test.name)
+ }
if failed {
t.Logf("\n%s", output)
}
printHdr := func(s string) {
if hdr != s {
pkg.Printf("\n%s\n\n", s)
+ hdr = s
}
}