-
Notifications
You must be signed in to change notification settings - Fork 5
/
.gitlab-ci.yml
68 lines (62 loc) · 1.68 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
workflow:
rules:
- if: '$CI_OPEN_MERGE_REQUESTS != null && ($CI_PIPELINE_SOURCE == "push" || $CI_PIPELINE_SOURCE == "webide")'
when: never
- when: always
# lint-ts-simulation:
# image: node:18
# before_script:
# - cd ts-simulation
# script:
# - yarn install --immutable
# - yarn lint
# test-ts-simulation:
# extends: .lint-ts-simulation
# before_script:
# - cd ts-simulation
# script:
# - yarn install --immutable
# - yarn test
lint-py-visualizer:
image: python:3.12
before_script:
- curl -sSL https://install.python-poetry.org | python3 -
- export PATH="/root/.local/bin:$PATH"
- cd py-visualizer
script:
- poetry install --no-root
- poetry run ruff check --fix
lint-go-client:
image: golang:1.21.0
before_script:
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.57.2
- cd go-client
script:
- go vet ./...
- go fmt ./...
- go mod tidy
- go mod verify
- golangci-lint run
test-go-client:
image: golang:1.21.0
before_script:
- cd go-client
script:
- go test -v provider/feed_provider_test.go
- go test -v sortition/sortition_test.go
test-go-client-docker:
image: docker
services:
- docker:dind
variables:
DOCKER_HOST: tcp://docker:2375
DOCKER_TLS_CERTDIR: ""
DOCKER_DRIVER: overlay2
before_script:
- cd go-client/tests
script:
- docker compose up ganache --detach
- VALUE_PROVIDER_IMPL=random docker compose up value-provider --detach
- docker compose up test-client --exit-code-from test-client
- docker compose stop ganache
- docker compose stop value-provider