52 lines
1016 B
YAML
52 lines
1016 B
YAML
stages:
|
|
- test
|
|
- build
|
|
|
|
|
|
test:
|
|
stage: test
|
|
image: python:3.8
|
|
script:
|
|
- python3.8 -m venv venv
|
|
- venv/bin/python -m pip install -r requirements-dev.txt
|
|
- venv/bin/python -m pip install -e .[dev]
|
|
- venv/bin/pytest --cov-report=term --cov-report=xml --junit-xml=report.xml
|
|
- venv/bin/flake8 src tests
|
|
- venv/bin/mypy --no-error-summary src tests
|
|
- venv/bin/pylint --jobs 0 --score n src tests
|
|
- venv/bin/yapf -dpr src tests
|
|
- venv/bin/sphinx-build docs public
|
|
coverage: '/\d+\%\s*$/'
|
|
artifacts:
|
|
paths:
|
|
- public
|
|
reports:
|
|
coverage_report:
|
|
coverage_format: cobertura
|
|
path: coverage.xml
|
|
junit: report.xml
|
|
|
|
|
|
build:
|
|
stage: build
|
|
image: python:3.8
|
|
script:
|
|
- python3.8 -m venv venv
|
|
- venv/bin/python -m pip install build
|
|
- venv/bin/python -m build .
|
|
artifacts:
|
|
paths:
|
|
- dist
|
|
|
|
|
|
pages:
|
|
stage: build
|
|
image: python:3.8
|
|
script:
|
|
- ls public
|
|
artifacts:
|
|
paths:
|
|
- public
|
|
only:
|
|
- master
|