Skip to content

Commit

Permalink
chore: attempt build fix
Browse files Browse the repository at this point in the history
`go tool cover` and `go test` create package paths differently
when code is not inside a "src" directory, and circleci doesn't clone
code into a src directory.

golang/go#17269
  • Loading branch information
chriscasola committed Mar 31, 2017
1 parent 3221f9a commit 3490904
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion circle.yml
Expand Up @@ -3,8 +3,11 @@ test:
- go vet ./...
- go get -u github.com/jstemmer/go-junit-report
- mkdir -p $CIRCLE_TEST_REPORTS/junit
- go test -v ./... | go-junit-report > $CIRCLE_TEST_REPORTS/junit/report.xml
- mkdir -p $CIRCLE_ARTIFACTS/coverage
- mkdir -p .go_workspace/src/github.com/chriscasola/nlp
- cp -R nlp/* .go_workspace/src/github.com/chriscasola/nlp/
- cd .go_workspace/src/github.com/chriscasola/nlp/
- go test -v ./... | go-junit-report > $CIRCLE_TEST_REPORTS/junit/report.xml
- go test -covermode=count -coverprofile=$CIRCLE_ARTIFACTS/coverage.out ./...
- go tool cover -html=$CIRCLE_ARTIFACTS/coverage.out -o $CIRCLE_ARTIFACTS/coverage.html
- go tool cover -func=$CIRCLE_ARTIFACTS/coverage.out -o $CIRCLE_ARTIFACTS/coverage.txt

0 comments on commit 3490904

Please sign in to comment.