Commit 1398d5df authored by endk-mirror-svc's avatar endk-mirror-svc

Fixed CI, hopefully :S

parent fcd1d1a0
Pipeline #24433067 failed with stages
in 58 seconds
cover
*.swp
image: golang:1.10
cache:
paths:
- /apt-cache
- /go/src/github.com
- /go/src/golang.org
- /go/src/google.golang.org
- /go/src/gopkg.in
stages:
- build
- test
- build
before_script:
- go get github.com/tools/godep
- mkdir -p /go/src/gitlab.com/MadsRC
- mkdir -p /go/src/gitlab.com/MadsRC /go/src/_/builds
- cp -r $CI_PROJECT_DIR /go/src/gitlab.com/MadsRC/go-eds
- cd /go/src/gitlab.com/MadsRC/go-eds
- ln -s /go/src/gitlab.com/MadsRC /go/src/_/builds/MadsRC
- make dep
build-my-project:
stage: build
unit_tests:
stage: test
script:
- make test
race_detector:
stage: test
script:
- godep restore
- godep go build
- make race
test-my-project:
memory_sanitizer:
stage: test
script:
- godep restore
- godep go test -v -cover ./...
- make msan
code_coverage:
stage: test
script:
- make coverage
lint_code:
stage: test
script:
- make lint
build:
stage: build
script:
- make
PROJECT_NAME := "go-eds"
PKG := "gitlab.com/MadsRC/$(PROJECT_NAME)"
PKG_LIST := $(shell go list ${PKG}/... | grep -v /vendor/)
GO_FILES := $(shell find . -name '*.go' | grep -v /vendor/ | grep -v _test.go)
.PHONY: all dep build clean test coverage lint
all: build
lint: ## Lint the files
@golint -set_exit_status ${PKG_LIST}
test: ## Run unittests
@go test -short ${PKG_LIST}
race: dep ## Run data race detector
@go test -race -short ${PKG_LIST}
msan: dep ## Run memory sanitizer
@go test -msan -short ${PKG_LIST}
coverage: ## Generate global code coverage report
go test -covermode=count -coverprofile=coverage.out
go tool cover -func=coverage.out
build: ## Build the binary file
@go build -i -v $(PKG)
help: ## Display this help screen
@grep -h -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment