diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5ae0f7215..c78fdab22 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,23 +2,39 @@ include: - project: cloud/integrations/ci file: - default.yml + - workflows/feature-branches.yml stages: + - build - test -test:acceptance: - stage: test +variables: + GOMODCACHE: $CI_PROJECT_DIR/.cache/go-mod + GOCACHE: $CI_PROJECT_DIR/.cache/go-build + +cache: + key: + files: + - go.mod + - go.sum + paths: + - $GOMODCACHE + +build: + stage: build image: golang:1.21 - except: - - tags script: - - make testacc + - go env + - go mod download -test:golangci-lint: +test:lint: stage: test - image: golangci/golangci-lint:v1.59.1 + image: golangci/golangci-lint:v1.59 script: - golangci-lint run -v - except: - - tags - - master + +test:unit: + stage: test + image: golang:1.21 + script: + - make test