.gitlab-ci.yml 1.06 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
build-mlmc:
niklas.baumgarten's avatar
niklas.baumgarten committed
6 7 8 9 10 11 12 13 14 15
  stage: build

  variables:
    GIT_SUBMODULE_STRATEGY: recursive

  before_script:
    - module add foss
    - module add Anaconda3

  script:
niklas.baumgarten's avatar
niklas.baumgarten committed
16
    - if [ -z "$UPSTREAM_COMMIT" ]; then
niklas.baumgarten's avatar
niklas.baumgarten committed
17 18
    -   echo "Using referenced mpp commit"
    - else
niklas.baumgarten's avatar
niklas.baumgarten committed
19
    -   echo ${UPSTREAM_COMMIT}
niklas.baumgarten's avatar
niklas.baumgarten committed
20
    - fi
niklas.baumgarten's avatar
niklas.baumgarten committed
21 22 23 24 25
    - tar xjf sprng5.tar.bz2
    - cd sprng5
    - ./configure --with-mpi=yes --with-fortran=no
    - make -j
    - cd ..
niklas.baumgarten's avatar
niklas.baumgarten committed
26

niklas.baumgarten's avatar
niklas.baumgarten committed
27 28 29
    - cd mpp
    - git fetch --all
    - git checkout $UPSTREAM_COMMIT
niklas.baumgarten's avatar
niklas.baumgarten committed
30
    - cd ..
31 32
    - mkdir build
    - cd build
niklas.baumgarten's avatar
niklas.baumgarten committed
33
    - cmake .. -DBUILD_MLMC_TESTS=OFF
niklas.baumgarten's avatar
niklas.baumgarten committed
34
    - make -j
niklas.baumgarten's avatar
niklas.baumgarten committed
35 36 37 38 39 40 41 42

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

niklas.baumgarten's avatar
niklas.baumgarten committed
45
test-mlmc:
46 47
  stage: test

niklas.baumgarten's avatar
niklas.baumgarten committed
48 49 50 51
  before_script:
    - module add foss
    - module add Anaconda3

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

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