Skip to content

dependent tiling

dependent tiling #2428

Workflow file for this run

# This workflow will install Python dependencies, run tests.
# For more information see:
# https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: tests
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
build:
runs-on: self-hosted
strategy:
matrix:
python-version: ["3.10"]
steps:
- name: Checkout github repo (+ download lfs dependencies)
uses: actions/checkout@v3
with:
lfs: true
- name: Install poetry
run: pipx install poetry
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: "poetry"
- name: Create environment variables
run: |
echo "BLISS_HOME=$GITHUB_WORKSPACE" >> $GITHUB_ENV
echo "JUPYTER_PLATFORM_DIRS=1" >> $GITHUB_ENV
echo "GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}" >> $GITHUB_ENV
- name: Install poetry dependencies
run: |
poetry install --sync
- name: Run black
run: |
poetry run black --check .
- name: Run flake8
run: |
poetry run flake8 bliss/ tests/ case_studies/
- name: Run pylint
run: |
poetry run pylint bliss/ tests/ case_studies/
- name: Run darglint
run: |
poetry run darglint bliss/ tests/
- name: Run Tests on the CPU
run: |
poetry run pytest --cov=./bliss --cov-report=xml --durations=0
- name: Run Tests on the GPU
run: |
poetry run pytest --gpu
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
flags: unittests
env_vars: OS,PYTHON
name: codecov-umbrella
fail_ci_if_error: true