From 03f92f206dd30cdf1215b65033b5643044603cf6 Mon Sep 17 00:00:00 2001 From: ale <ale@incal.net> Date: Fri, 29 Jan 2021 11:15:40 +0000 Subject: [PATCH] Add explicit test CI stage with coverage report artifacts --- .gitlab-ci.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2be34afc..08bb3e03 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1 +1,26 @@ include: "https://git.autistici.org/ai3/build-deb/raw/master/ci-nextstable.yml" + +stages: + - test + - build_pkgsrc + - build_pkg + - upload_pkg + +build_pkgsrc:bullseye: + only: + - master + +build_pkg:bullseye:amd64: + only: + - master + +test: + stage: test + image: golang:1.14 + script: + - go get github.com/boumenot/gocover-cobertura + - go test -v -cover -coverprofile=cover.out ./... + - gocover-cobertura < cover.out > cover.xml + artifacts: + reports: + cobertura: cover.xml -- GitLab