forked from robotics-erlangen/autoref
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
78 lines (72 loc) · 1.71 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
69
70
71
72
73
74
75
76
77
78
default:
image: ci:ubuntu-18.04
variables:
GIT_SUBMODULE_STRATEGY: recursive
compile-autoref:
script:
- mkdir -p build
- cd build
- cmake -GNinja ..
- cmake --build .
stage: build
cache:
# Increase the number in the cache key to start with
# a fresh build cache. This is only useful in case of
# build system bug and/or updates of ExternalProjects!
key: "default-4"
paths:
- build/
artifacts:
paths:
- build/bin/
expire_in: 1 day
compile-framework:
script:
- cd src/framework
- mkdir -p build
- cd build
- cmake -GNinja ..
- cmake --build .
stage: build
cache:
# Increase the number in the cache key to start with
# a fresh build cache. This is only useful in case of
# build system bug and/or updates of ExternalProjects!
key: "default-4"
paths:
- src/framework/build/
artifacts:
paths:
- src/framework/build/bin/
expire_in: 1 day
run_replay_tests:
script:
- "echo running replay tests"
- "[[ ! -d autoref-tests ]] && git lfs clone https://gitlab.com/robocup-small-size/autoref-tests.git"
- "cd autoref-tests"
- "git pull"
- "cd .."
- "cd cmake"
- "python3 run_autoref_tests.py ../autoref-tests ../autoref/init.lua ../src/framework/build/bin/replay-cli"
stage: test
dependencies:
- compile-framework
cache:
key: "replay-tests"
paths:
- autoref-tests/
.test: &test_template
script:
- "echo running test \"$TEST_PATTERN\""
- "cd build"
- "cmake -GNinja .."
- "ctest --output-on-failure -R \"$TEST_PATTERN\""
stage: test
cache:
key: "tests"
paths:
- build/
tests:
<<: *test_template
variables:
TEST_PATTERN: "."