.gitlab-ci.yml 808 Bytes
Newer Older
1
2
3
variables:
  DOCKER_IMAGE: dpsim-dev-${CI_COMMIT_REF_NAME}

4
5
stages:
  - prepare
Georg Martin Reinke's avatar
Georg Martin Reinke committed
6
  - build-cim
7
  - build
Georg Martin Reinke's avatar
Georg Martin Reinke committed
8
  - test
9

10
11
12
before_script:
  - git submodule foreach git checkout .

13
14
15
docker:
  stage: prepare
  script:
16
    - docker build -t ${DOCKER_IMAGE} .
17
18
19
  tags:
    - shell

Georg Martin Reinke's avatar
Georg Martin Reinke committed
20
21
22
23
24
25
26
27
28
29
30
31
build-cim:
  stage: build-cim
  script:
    - mkdir -p Source/CIM-XML-Parser/build
    - cd Source/CIM-XML-Parser/build
    - cmake -DBUILD_SHARED_LIBS=ON ..
    - make
    - cp libCIMParser.so thirdparty/arabica/libarabica.so /usr/local/lib
  image: ${DOCKER_IMAGE}
  tags:
    - docker

32
33
34
35
build:
  stage: build
  script:
    - make -C Source
36
  image: ${DOCKER_IMAGE}
37
  tags:
Georg Martin Reinke's avatar
Georg Martin Reinke committed
38
39
40
41
42
    - docker

test:
  stage: test
  script:
Georg Martin Reinke's avatar
Georg Martin Reinke committed
43
    - make -C Source tests
Georg Martin Reinke's avatar
Georg Martin Reinke committed
44
    - cd Source/Tests
Georg Martin Reinke's avatar
Georg Martin Reinke committed
45
    - python3 run_tests.py
46
  image: ${DOCKER_IMAGE}
Georg Martin Reinke's avatar
Georg Martin Reinke committed
47
48
  tags:
    - docker