Update Travis to test multiple golang versions.

This commit is contained in:
David Hill 2016-08-16 13:40:47 -04:00 committed by Dave Collins
parent f438166ffd
commit 6cf5744a04
2 changed files with 7 additions and 3 deletions

View File

@ -1,7 +1,10 @@
language: go language: go
go: 1.2 go:
- 1.5.4
- 1.6.3
- 1.7
install: install:
- go get -v code.google.com/p/go.tools/cmd/cover - go get -v golang.org/x/tools/cmd/cover
script: script:
- go test -v -tags=disableunsafe ./spew - go test -v -tags=disableunsafe ./spew
- go test -v -tags=testcgo ./spew -covermode=count -coverprofile=profile.cov - go test -v -tags=testcgo ./spew -covermode=count -coverprofile=profile.cov

View File

@ -59,10 +59,11 @@ func addCgoDumpTests() {
v3Len := fmt.Sprintf("%d", v3l) v3Len := fmt.Sprintf("%d", v3l)
v3Cap := fmt.Sprintf("%d", v3c) v3Cap := fmt.Sprintf("%d", v3c)
v3t := "[6]testdata._Ctype_unsignedchar" v3t := "[6]testdata._Ctype_unsignedchar"
v3t2 := "[6]testdata._Ctype_uchar"
v3s := "(len=" + v3Len + " cap=" + v3Cap + ") " + v3s := "(len=" + v3Len + " cap=" + v3Cap + ") " +
"{\n 00000000 74 65 73 74 33 00 " + "{\n 00000000 74 65 73 74 33 00 " +
" |test3.|\n}" " |test3.|\n}"
addDumpTest(v3, "("+v3t+") "+v3s+"\n") addDumpTest(v3, "("+v3t+") "+v3s+"\n", "("+v3t2+") "+v3s+"\n")
// C signed char array. // C signed char array.
v4, v4l, v4c := testdata.GetCgoSignedCharArray() v4, v4l, v4c := testdata.GetCgoSignedCharArray()