Update TravisCI to goclean script.

Also, correct a couple of issues found by running the script.
This commit is contained in:
Dave Collins 2014-12-22 20:05:11 -06:00
parent 968b6da5db
commit 9c8ee93b5c
3 changed files with 13 additions and 14 deletions

View file

@ -1,17 +1,15 @@
language: go language: go
go: go: release
- 1.2 before_install:
- release - gocleandeps=c16c849abae90c23419d
- tip - git clone https://gist.github.com/$gocleandeps.git
- goclean=71d0380287747d956a26
- git clone https://gist.github.com/$goclean.git
install: install:
- go get -d -t -v ./... - go get -d -t -v ./...
- go get -v code.google.com/p/go.tools/cmd/vet - bash $gocleandeps/gocleandeps.sh
- go get -v github.com/GeertJohan/fgt
- go get -v github.com/golang/lint/golint
script: script:
- export PATH=$PATH:$HOME/gopath/bin - export PATH=$PATH:$HOME/gopath/bin
- go vet ./... - bash $goclean/goclean.sh
- fgt golint . after_success:
- fgt golint memdb - goveralls -coverprofile=profile.cov -service=travis-ci
- fgt golint ldb
- go test -v

View file

@ -6,6 +6,7 @@ package btcdb_test
import ( import (
"fmt" "fmt"
"github.com/conformal/btcdb" "github.com/conformal/btcdb"
_ "github.com/conformal/btcdb/memdb" _ "github.com/conformal/btcdb/memdb"
"github.com/conformal/btcnet" "github.com/conformal/btcnet"

View file

@ -199,7 +199,7 @@ func testBackout(t *testing.T) {
return return
} }
if _, err := db.ExistsSha(sha); err != nil { if _, err := db.ExistsSha(sha); err != nil {
t.Errorf("ExistsSha: unexpected error: %v") t.Errorf("ExistsSha: unexpected error: %v", err)
} }
_, err = db.FetchBlockBySha(sha) _, err = db.FetchBlockBySha(sha)
if err != nil { if err != nil {
@ -213,7 +213,7 @@ func testBackout(t *testing.T) {
return return
} }
if _, err := db.ExistsSha(sha); err != nil { if _, err := db.ExistsSha(sha); err != nil {
t.Errorf("ExistsSha: unexpected error: %v") t.Errorf("ExistsSha: unexpected error: %v", err)
} }
_, err = db.FetchBlockBySha(sha) _, err = db.FetchBlockBySha(sha)
if err != nil { if err != nil {