1
0
mirror of https://github.com/golang/go synced 2024-10-04 22:21:22 -06:00
go/src
Dave Cheney 62baae6e57 unicode/utf16: add explicit test for decoding invalid runes.
The EncodeRune test exercises DecodeRune, but only for runes that it can encode. Add an explicit test for invalid utf16 surrogate pairs.

Bonus: coverage is now 100%

unicode/utf16/utf16.go: IsSurrogate     100.0%
unicode/utf16/utf16.go: DecodeRune      100.0%
unicode/utf16/utf16.go: EncodeRune      100.0%
unicode/utf16/utf16.go: Encode          100.0%
unicode/utf16/utf16.go: Decode          100.0%
total:                  (statements)    100.0%

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/39150044
2013-12-16 12:35:25 +11:00
..
cmd cmd/5a, cmd/6a, cmd/8a: fix .y files to match y.tab.[ch] 2013-12-11 12:11:37 -05:00
lib9 all: compiler/bootstrap for dragonfly/amd64 2013-08-24 01:18:04 +10:00
libbio build: do not use the host's libbio on Plan 9 2013-12-09 18:39:58 -05:00
liblink liblink: fix extern register accesses on Plan 9 (386) 2013-12-09 18:48:44 -05:00
libmach libmach: accept OS X binary generated by external linker 2013-09-10 11:50:34 -07:00
pkg unicode/utf16: add explicit test for decoding invalid runes. 2013-12-16 12:35:25 +11:00
all.bash
all.bat
all.rc
clean.bash
clean.bat
clean.rc
make.bash cmd/dist, build: support building statically linked toolchain 2013-10-01 23:44:20 -04:00
make.bat cmd/dist: fix windows build. 2013-08-02 14:29:04 -07:00
Make.dist
make.rc build: fix make.rc on Plan 9 2013-05-24 13:55:19 -07:00
race.bash race.bash, race.bat: build a race enabled cmd/cgo before trying to use it 2013-09-29 10:34:41 +10:00
race.bat race.bash, race.bat: build a race enabled cmd/cgo before trying to use it 2013-09-29 10:34:41 +10:00
run.bash cgo: enable cgo on dragonfly 2013-09-04 15:19:21 -07:00
run.bat runtime/race: add end-to-end test on windows 2013-08-15 12:13:00 +10:00
run.rc build: remove builder from test suite (fix build) 2013-08-01 13:49:00 +10:00
sudo.bash cmd/cov: delete 2013-05-24 11:06:06 -07:00