.gitlab-ci.yml 1.01 KB
Newer Older
1
image: "dbisilm/nvm-based_data_structures:latest"
2
3
4
5
6
7
8

stages:
  - build
  - test

build:
  stage: build
9
  tags: grouprunner
10
11
12
  script:
    - mkdir build
    - cd build
13
    - cmake -DCMAKE_BUILD_TYPE=Release ../src
14
    - make
15
16
17
    # clean up unnecessary files and strip binaries
    - rm -rf _deps *tree generated
    - strip bench/point bench/scan bench/tree_* test/*Test
18
19
  artifacts:
    paths:
20
      - build/
21
    expire_in: 30 minutes
22
23
24

test:
  stage: test
25
  tags: grouprunner
26
  script:
27
28
    - echo pass | sudo -S mkdir -m 777 -p /mnt/pmem/test
    - cd build
29
    - ctest
30
31
  dependencies:
    - build
32

33
34
coverage:
  stage: build
35
  tags: grouprunner
36
37
38
39
40
41
42
43
44
45
46
47
  script:
    - echo pass | sudo -S dnf -y install python-pip
    - pip install gcovr --user
    - mkdir build
    - cd build
    - cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_FLAGS="-g -O0 -fprofile-arcs -ftest-coverage" ../src
    - make
    - echo pass | sudo -S mkdir -m 777 -p /mnt/pmem/test
    - ctest
    - ~/.local/bin/gcovr -r .. --exclude _deps
  coverage: '/^TOTAL.*\s+(\d+\%)$/'