.gitlab-ci.yml 1.01 KB
Newer Older
niklas.baumgarten's avatar
niklas.baumgarten committed
1
stages:
niklas.baumgarten's avatar
niklas.baumgarten committed
2 3 4
  - build
  - test

niklas.baumgarten's avatar
niklas.baumgarten committed
5 6 7 8
cache:
  paths:
    - sprng5
    
niklas.baumgarten's avatar
niklas.baumgarten committed
9
before_script:
niklas.baumgarten's avatar
niklas.baumgarten committed
10 11
    - module add foss
    - module add Anaconda3
niklas.baumgarten's avatar
niklas.baumgarten committed
12 13 14 15
    - tar xjf sprng5.tar.bz2
    - cd sprng5
    - ./configure --with-mpi=yes --with-fortran=no
    - make -j
niklas.baumgarten's avatar
niklas.baumgarten committed
16
    - cd ..
niklas.baumgarten's avatar
niklas.baumgarten committed
17

niklas.baumgarten's avatar
niklas.baumgarten committed
18
build-mlmc:
niklas.baumgarten's avatar
niklas.baumgarten committed
19 20 21 22 23 24
  stage: build

  variables:
    GIT_SUBMODULE_STRATEGY: recursive

  script:
niklas.baumgarten's avatar
niklas.baumgarten committed
25
    - if [ -z "$UPSTREAM_COMMIT" ]; then
niklas.baumgarten's avatar
niklas.baumgarten committed
26 27
    -   echo "Using referenced mpp commit"
    - else
niklas.baumgarten's avatar
niklas.baumgarten committed
28
    -   echo ${UPSTREAM_COMMIT}
niklas.baumgarten's avatar
niklas.baumgarten committed
29
    - fi
niklas.baumgarten's avatar
niklas.baumgarten committed
30 31 32
    - cd mpp
    - git fetch --all
    - git checkout $UPSTREAM_COMMIT
niklas.baumgarten's avatar
niklas.baumgarten committed
33
    - cd ..
34 35
    - mkdir build
    - cd build
niklas.baumgarten's avatar
niklas.baumgarten committed
36
    - cmake .. -DBUILD_MLMC_TESTS=OFF
niklas.baumgarten's avatar
niklas.baumgarten committed
37
    - make -j
niklas.baumgarten's avatar
niklas.baumgarten committed
38 39 40 41 42 43 44

  artifacts:
    paths:
      - build/mpp/src
      - build/mpp/LIB_PS
      - build/mpp/googletest
      - build/mlmc
niklas.baumgarten's avatar
niklas.baumgarten committed
45
    expire_in: '1h'
niklas.baumgarten's avatar
niklas.baumgarten committed
46

niklas.baumgarten's avatar
niklas.baumgarten committed
47
test-mlmc:
48 49 50
  stage: test

  script:
niklas.baumgarten's avatar
niklas.baumgarten committed
51 52 53
    - cd build
    - cmake ..
    - make -j
54 55
    - cd tests
    - mpirun -n 4 TestMainProgram
56
    - mpirun -n 4 TestMultilevelPlotter
niklas.baumgarten's avatar
niklas.baumgarten committed
57
    - touch dummy_results.txt
niklas.baumgarten's avatar
niklas.baumgarten committed
58

niklas.baumgarten's avatar
niklas.baumgarten committed
59 60 61
  artifacts:
    paths:
      - build/dummy_results.txt