Skip to content
Snippets Groups Projects
Commit b898851b authored by Rick Carback's avatar Rick Carback
Browse files

Update build to use go-acc

parent 9b897c95
No related branches found
No related tags found
No related merge requests found
...@@ -9,7 +9,7 @@ cache: ...@@ -9,7 +9,7 @@ cache:
variables: variables:
REPO_DIR: gitlab.com/elixxir REPO_DIR: gitlab.com/elixxir
REPO_NAME: registration REPO_NAME: registration
DOCKER_IMAGE: golang:1.13.4-buster DOCKER_IMAGE: elixxirlabs/cuda-go:latest
MIN_CODE_COVERAGE: "0.0" MIN_CODE_COVERAGE: "0.0"
before_script: before_script:
...@@ -23,7 +23,7 @@ before_script: ...@@ -23,7 +23,7 @@ before_script:
- chmod 700 ~/.ssh - chmod 700 ~/.ssh
- ssh-keyscan -t rsa gitlab.com > ~/.ssh/known_hosts - ssh-keyscan -t rsa gitlab.com > ~/.ssh/known_hosts
- git config --global url."git@gitlab.com:".insteadOf "https://gitlab.com/" - git config --global url."git@gitlab.com:".insteadOf "https://gitlab.com/"
- export GOFLAGS=-mod=vendor - export PATH=$HOME/go/bin:$PATH
- export GOPRIVATE=gitlab.com/elixxir/* - export GOPRIVATE=gitlab.com/elixxir/*
stages: stages:
...@@ -52,13 +52,9 @@ test: ...@@ -52,13 +52,9 @@ test:
except: except:
- tags - tags
script: script:
- GO111MODULE=off go get -u github.com/haya14busa/goverage
- apt-get update
- apt-get install bc -y
- mkdir -p testdata - mkdir -p testdata
# Test coverage # Test coverage
- goverage -coverprofile=testdata/coverage-real.out -v ./... 2>&1 | grep -v "no packages being tested depend on" - go-acc --covermode atomic --output testdata/coverage.out ./... -- -v
# Exclude cmd from test coverage as it is command line related tooling # Exclude cmd from test coverage as it is command line related tooling
# - grep -v -e cmd testdata/coverage.out > testdata/coverage-real.out # - grep -v -e cmd testdata/coverage.out > testdata/coverage-real.out
- go tool cover -func=testdata/coverage-real.out - go tool cover -func=testdata/coverage-real.out
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment