This repository has been archived on 2020-09-27. You can view files and clone it, but cannot push or open issues or pull requests.
thrempp/.gitlab-ci.yml

36 lines
882 B
YAML

image: golang:latest
stages:
- build
- test
before_script:
- curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
- mkdir -p /go/src/$CI_PROJECT_PATH/
- cp -R $CI_PROJECT_DIR /go/src/dev.sum7.eu/$CI_PROJECT_PATH
- cd /go/src/dev.sum7.eu/$CI_PROJECT_PATH
- dep ensure
build-my-project:
stage: build
script:
- mkdir /builds/freifunkbremen/thrempp/bin/
- cp /go/bin/thrempp /builds/$CI_PROJECT_PATH/bin/$CI_PROJECT_NAME
artifacts:
paths:
- bin/thrempp
- config_example.toml
- config-respondd_example.toml
test-my-project:
stage: test
script:
- ./.circleci/check-gofmt
- ./.circleci/check-testfiles
- go test $(go list ./... | grep -v /vendor/) -v -coverprofile .testCoverage.txt
- go tool cover -func=.testCoverage.txt
test-race-my-project:
stage: test
script:
- go test -race ./...