diff options
author | Ondřej Surý <ondrej@sury.org> | 2011-01-17 12:40:45 +0100 |
---|---|---|
committer | Ondřej Surý <ondrej@sury.org> | 2011-01-17 12:40:45 +0100 |
commit | 3e45412327a2654a77944249962b3652e6142299 (patch) | |
tree | bc3bf69452afa055423cbe0c5cfa8ca357df6ccf /src/pkg/compress/zlib | |
parent | c533680039762cacbc37db8dc7eed074c3e497be (diff) | |
download | golang-upstream/2011.01.12.tar.gz |
Imported Upstream version 2011.01.12upstream/2011.01.12
Diffstat (limited to 'src/pkg/compress/zlib')
-rw-r--r-- | src/pkg/compress/zlib/Makefile | 2 | ||||
-rw-r--r-- | src/pkg/compress/zlib/reader_test.go | 12 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/pkg/compress/zlib/Makefile b/src/pkg/compress/zlib/Makefile index 4cfda4f1b..791072d34 100644 --- a/src/pkg/compress/zlib/Makefile +++ b/src/pkg/compress/zlib/Makefile @@ -2,7 +2,7 @@ # Use of this source code is governed by a BSD-style # license that can be found in the LICENSE file. -include ../../../Make.$(GOARCH) +include ../../../Make.inc TARG=compress/zlib GOFILES=\ diff --git a/src/pkg/compress/zlib/reader_test.go b/src/pkg/compress/zlib/reader_test.go index 8ae8d0070..eaefc3a36 100644 --- a/src/pkg/compress/zlib/reader_test.go +++ b/src/pkg/compress/zlib/reader_test.go @@ -22,13 +22,13 @@ type zlibTest struct { // http://www.zlib.net/zpipe.c var zlibTests = []zlibTest{ - zlibTest{ + { "empty", "", []byte{0x78, 0x9c, 0x03, 0x00, 0x00, 0x00, 0x00, 0x01}, nil, }, - zlibTest{ + { "goodbye", "goodbye, world", []byte{ @@ -38,25 +38,25 @@ var zlibTests = []zlibTest{ }, nil, }, - zlibTest{ + { "bad header", "", []byte{0x78, 0x9f, 0x03, 0x00, 0x00, 0x00, 0x00, 0x01}, HeaderError, }, - zlibTest{ + { "bad checksum", "", []byte{0x78, 0x9c, 0x03, 0x00, 0x00, 0x00, 0x00, 0xff}, ChecksumError, }, - zlibTest{ + { "not enough data", "", []byte{0x78, 0x9c, 0x03, 0x00, 0x00, 0x00}, io.ErrUnexpectedEOF, }, - zlibTest{ + { "excess data is silently ignored", "", []byte{ |