diff options
author | feistel <6742251-feistel@users.noreply.gitlab.com> | 2021-08-26 09:02:38 +0300 |
---|---|---|
committer | feistel <6742251-feistel@users.noreply.gitlab.com> | 2021-11-03 02:44:08 +0300 |
commit | a3bf20e9a6fb8da3622ef4f610fcc98c16a55ab7 (patch) | |
tree | 076da37faa2029a58a3c6ce52920f1a0689335bd /.gitlab/ci/test.yml | |
parent | 2b5f9c3202c73306a6d7bafb58b7570b7dfec87d (diff) |
ci: refactor ci jobs
Diffstat (limited to '.gitlab/ci/test.yml')
-rw-r--r-- | .gitlab/ci/test.yml | 37 |
1 files changed, 14 insertions, 23 deletions
diff --git a/.gitlab/ci/test.yml b/.gitlab/ci/test.yml index e778214f..524678c6 100644 --- a/.gitlab/ci/test.yml +++ b/.gitlab/ci/test.yml @@ -1,50 +1,39 @@ .tests-common: - extends: .go-mod-cache - stage: test + extends: .common needs: ['download deps'] artifacts: reports: junit: junit-test-report.xml -.tests-unit: +.tests-matrix: extends: .tests-common + image: golang:${GO_VERSION} + parallel: + matrix: + - GO_VERSION: ["1.16", "1.17"] + +tests: + extends: .tests-matrix script: - echo "Running all unit tests..." - make test ARGS='-short' -.tests-acceptance: - extends: .tests-common +tests-acceptance: + extends: .tests-matrix script: - echo "Running just the acceptance tests...." - make acceptance -test:1.16: - extends: .tests-unit - image: golang:1.16 - -test-acceptance:1.16: - extends: .tests-acceptance - image: golang:1.16 - -test:1.17: - extends: .tests-unit - image: golang:1.17 - -test-acceptance:1.17: - extends: .tests-acceptance - image: golang:1.17 - race: extends: .tests-common script: - echo "Running race detector" - - make setup - make race cover: extends: .tests-common script: - - make generate-mocks + - echo "Running coverage testing" - make cover coverage: '/total:.+\(statements\).+\d+\.\d+/' artifacts: @@ -69,5 +58,7 @@ code_quality: check deps: extends: .tests-common + before_script: + - echo skipping script: - make deps-check |