.gitlab-ci.yml 1.47 KB
Newer Older
myron's avatar
myron committed
1
2
3
stages:
  - test
#  - deploy
Alessandro Mirone's avatar
Alessandro Mirone committed
4

myron's avatar
myron committed
5
6
7
8
variables:
  PROJECT_NAME: "xrstools"
  LOCAL_REPO: "/dev/shm/gitlab_ci/xrstools"
  VENV_DIR: /dev/shm/gitlab_ci/xrstools/venv
myron's avatar
myron committed
9
  USE_CLEAN_VENV: "false"
myron's avatar
myron committed
10
  CLEAN_RESULTS: "true"
Alessandro Mirone's avatar
Alessandro Mirone committed
11

myron's avatar
myron committed
12
test:
Alessandro Mirone's avatar
Alessandro Mirone committed
13
14
  stage: test
  only:
myron's avatar
myron committed
15
    - nocdi
Alessandro Mirone's avatar
Alessandro Mirone committed
16
  tags:
myron's avatar
myron committed
17
18
19
20
21
22
23
24
25
    - scisoft10
  before_script:
    - unset HTTP_PROXY
    - unset HTTPS_PROXY
    - if [ ! -d $LOCAL_REPO ]; then mkdir -p $LOCAL_REPO; fi
    - if [ -d $VENV_DIR ]; then if [ "$USE_CLEAN_VENV" == "true" ]; then rm -rf $VENV_DIR; fi; fi
    - python3 -m venv $VENV_DIR
    - source $VENV_DIR/bin/activate
    - echo "Running $(python --version) from $(which python) on $(hostname) ($(arch))"
myron's avatar
myron committed
26
 
myron's avatar
myron committed
27
28
    - pip install  --upgrade  pip setuptools wheel
    - pip install --upgrade numpy silx
myron's avatar
myron committed
29
    - pip install PyQt5  
Alessandro Mirone's avatar
Alessandro Mirone committed
30
    - pip install -r requirements.txt
myron's avatar
myron committed
31
    - pip install .
myron's avatar
myron committed
32
33

  script:
myron's avatar
test    
myron committed
34
    - pwd
myron's avatar
myron committed
35
    - cd nonregressions/xes
myron's avatar
myron committed
36
    - /usr/bin/xvfb-run --server-args="-screen 0 1024x768x24" -a python xes_analysis.py >| output
myron's avatar
myron committed
37
    - cd ../xrs_raman
myron's avatar
myron committed
38
39
40
    - /usr/bin/xvfb-run --server-args="-screen 0 1024x768x24" -a python non_reg_testing_XRS.py >| output1
    - /usr/bin/xvfb-run --server-args="-screen 0 1024x768x24" -a python non_reg_testing_XRS_small.py >| output2
    - /usr/bin/xvfb-run --server-args="-screen 0 1024x768x24" -a python non_reg_testing_XRS_raman_extraction.py >| output3
myron's avatar
myron committed
41
    - cd ../volumes/test1
myron's avatar
myron committed
42
    - /usr/bin/xvfb-run --server-args="-screen 0 1024x768x24" -a python test.py >| output
Alessandro Mirone's avatar
Alessandro Mirone committed
43
44
45
    - deactivate
  after_script:
    - pwd
myron's avatar
myron committed
46
    
myron's avatar
test    
myron committed
47