diff --git a/src/compress/gzip/gzip_test.go b/src/compress/gzip/gzip_test.go index 12c8e182078..5aeb2e2675d 100644 --- a/src/compress/gzip/gzip_test.go +++ b/src/compress/gzip/gzip_test.go @@ -200,6 +200,11 @@ func TestWriterFlush(t *testing.T) { if n2 == n3 { t.Fatal("Flush didn't flush any data") } + + if err := w.Close(); err != nil { + t.Fatal(err) + } + } // Multiple gzip files concatenated form a valid gzip file.