WIP: test setting python path #7
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Push to main | |
on: | |
push: | |
branches: | |
- "add_github_actions" | |
paths: | |
- ".github/workflows/push_to_main.yml" | |
pull_request: | |
branches: | |
- "main" | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python 3.9 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.9 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements_dev.txt | |
pip install sphinx sphinx-rtd-theme # Install Sphinx and a theme (e.g., Read the Docs theme) | |
- name: Run pre-commit hooks | |
run: pre-commit run --all-files | |
# - name: Run coverage | |
# run: | | |
# coverage run --concurrency=multiprocessing --parallel-mode -m pytest tests --junitxml=tests/pytest.xml | |
# coverage combine | |
# coverage report --format=text -m |tee tests/pytest-coverage.txt | |
- name: Run tests | |
working-directory: ./tests | |
run: | | |
export PYTHONPATH="${PYTHONPATH}:$(dirname $(pwd))" | |
pytest | |
- name: Build documentation with Sphinx | |
run: | | |
sphinx-build -b html src/dcm_classifier documentation |