From 36efa38103d877dbd8295e1adfd6786e43ec579f Mon Sep 17 00:00:00 2001 From: Martin Riedl Date: Sat, 24 Jul 2021 19:22:47 +0200 Subject: [PATCH] use new CI script --- .gitlab-ci.yml | 41 +++-------------------------------------- 1 file changed, 3 insertions(+), 38 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b8a1dd0..018b82e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,38 +1,3 @@ -image: golang:latest - -stages: - - test - -validate lint: - stage: test - script: - - go get -u golang.org/x/lint/golint - - golint -set_exit_status ./... - -execute tests: - stage: test - script: - - go test ./... - -race detection: - stage: test - script: - - go test -race ./... - -code coverage: - stage: test - script: - - go test -covermode=count -coverprofile coverage.cov ./... - - go tool cover -func=coverage.cov - - mkdir $CI_PROJECT_DIR/report - - go tool cover -html=coverage.cov -o $CI_PROJECT_DIR/report/coverage.html - coverage: '/\(statements\)\W+\d+\.\d+%/' - artifacts: - paths: - - report/ - -codecov.io: - stage: test - script: - - go test -race -coverprofile=coverage.txt -covermode=atomic ./... - - bash <(curl -s https://codecov.io/bash) +include: + - project: 'martinr92/gitlab-ci' + file: '.gitlab-ci-gomod-build-template.yml'