image: $CONTAINER_TEST_IMAGE variables: CONTAINER_TEST_IMAGE: gitlab-registry.mpcdf.mpg.de/ift/nifty-dev:$CI_BUILD_REF_NAME OMP_NUM_THREADS: 1 stages: - build_docker - test - release - demo_runs build_docker_from_scratch: only: - schedules image: docker:stable stage: build_docker script: - docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN gitlab-registry.mpcdf.mpg.de - docker build -t $CONTAINER_TEST_IMAGE --no-cache . - docker push $CONTAINER_TEST_IMAGE build_docker_from_cache: except: - schedules image: docker:stable stage: build_docker script: - docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN gitlab-registry.mpcdf.mpg.de - docker build -t $CONTAINER_TEST_IMAGE . - docker push $CONTAINER_TEST_IMAGE test_python2_with_coverage: stage: test script: - python setup.py install --user -f - mpiexec -n 2 --bind-to none nosetests -q 2> /dev/null - nosetests -q --with-coverage --cover-package=nifty5 --cover-erase - > coverage report --omit "*plotting*,*distributed_do*" - > coverage report --omit "*plotting*,*distributed_do*" | grep TOTAL | awk '{ print "TOTAL: "$4; }' test_python3: stage: test script: - python3 setup.py install --user -f - nosetests3 -q - mpiexec -n 2 --bind-to none nosetests3 -q 2> /dev/null pages: stage: release script: - python setup.py install --user -f - sh docs/generate.sh - mv docs/build/ public/ artifacts: paths: - public only: - NIFTy_4 before_script: - export MPLBACKEND="agg" run_ipynb: stage: demo_runs script: - python setup.py install --user -f - python3 setup.py install --user -f - jupyter nbconvert --execute --ExecutePreprocessor.timeout=None demos/Wiener_Filter.ipynb artifacts: paths: - '*.png' run_getting_started_1: stage: demo_runs script: - python demos/getting_started_1.py - python3 demos/getting_started_1.py # # TODO Please uncomment this as soon as the demo is working # run_getting_started_2: # stage: demo_runs # script: # - python demos/getting_started_2.py # - python3 demos/getting_started_2.py