-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
55 lines (53 loc) · 1.4 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
stages:
- test
variables:
HOST: 127.0.0.1
PORT: 3000
test:
image: python:3.9-alpine
stage: test
tags:
- public-docker
parallel:
matrix:
- TEST_SCRIPT:
- integrationtests/test_ram_check
TEST_RESULT:
- 100%
- TEST_SCRIPT:
- integrationtests/test_ram_check_85
TEST_RESULT:
- 25%
- TEST_SCRIPT:
- integrationtests/test_ram_check_critical
TEST_RESULT:
- 0%
- TEST_SCRIPT:
- integrationtests/test_load_check_critical
TEST_RESULT:
- 1%
- TEST_SCRIPT:
- integrationtests/test_load_check
TEST_RESULT:
- 100%
- TEST_SCRIPT:
- integrationtests/test_load_check_75
TEST_RESULT:
- 25%
- TEST_SCRIPT:
- integrationtests/test_load_check_100
TEST_RESULT:
- 10%
- TEST_SCRIPT:
- integrationtests/test_build_in_checks
TEST_RESULT:
- any
script:
- apk add gcc build-base linux-headers git
- git submodule update --init
- pip install -r buildins/requirements.txt
- python agent.py -host $HOST -p $PORT $TEST_SCRIPT &
- sleep 5 # wait for server to boot up
- python tests/test_client.py > result.out
- cat result.out
- if [ "$(cat result.out)" = "$TEST_RESULT" ] || [ "$TEST_RESULT" = "any" ] ; then exit 0; else exit 1; fi