123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138 |
- stages:
- - build
- - test
- - deploy
- webui:
- stage: build
- image: node:14
- cache:
- paths:
- - webui/node_modules/
- before_script:
- - cd webui/
- - npm install
- script:
- - npm run build
- artifacts:
- expire_in: 1 day
- paths:
- - webui/dist/
- tests_3.6:
- stage: test
- image: python:3.6
- only:
- - master
- variables:
- PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
- cache:
- key: "$CI_JOB_NAME"
- paths:
- - .cache/pip
- - env/
- before_script:
- - python -V
- - python -m venv env
- - source env/bin/activate
- - pip install coverage
- script:
- - coverage run --source=pycs/ -m unittest discover test/
- tests_3.7:
- stage: test
- image: python:3.7
- only:
- - master
- variables:
- PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
- cache:
- key: "$CI_JOB_NAME"
- paths:
- - .cache/pip
- - env/
- before_script:
- - python -V
- - python -m venv env
- - source env/bin/activate
- - pip install coverage
- script:
- - coverage run --source=pycs/ -m unittest discover test/
- tests_3.8:
- stage: test
- image: python:3.8
- only:
- - master
- variables:
- PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
- cache:
- key: "$CI_JOB_NAME"
- paths:
- - .cache/pip
- - env/
- before_script:
- - python -V
- - python -m venv env
- - source env/bin/activate
- - pip install coverage
- script:
- - coverage run --source=pycs/ -m unittest discover test/
- tests_3.9:
- stage: test
- image: python:3.9
- variables:
- PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
- cache:
- key: "$CI_JOB_NAME"
- paths:
- - .cache/pip
- - env/
- before_script:
- - python -V
- - python -m venv env
- - source env/bin/activate
- - pip install coverage
- script:
- - coverage run --source=pycs/ -m unittest discover test/
- - coverage report -m
- tests_3.10:
- stage: test
- image: python:3.10-rc
- allow_failure: true
- only:
- - master
- variables:
- PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
- cache:
- key: "$CI_JOB_NAME"
- paths:
- - .cache/pip
- - env/
- before_script:
- - python -V
- - python -m venv env
- - source env/bin/activate
- - pip install coverage
- script:
- - coverage run --source=pycs/ -m unittest discover test/
- bundle:
- stage: deploy
- image: alpine
- script:
- - mv webui/dist dist
- - rm -rf webui
- - mv dist webui
- artifacts:
- expire_in: 30 days
- paths:
- - settings.json
- - app.py
- - pycs/
- - webui/
|