Promote from BLAIS5-3953 to main #186
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: Run Tests | |
on: | |
pull_request: | |
branches: [ main ] | |
push: | |
branches: [ main ] | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: [ "3.9", "3.10" ] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install poetry | |
run: pip install poetry | |
- name: Install dependencies | |
run: poetry install | |
- name: Run linter | |
run: poetry run black --check . | |
check-types: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: [ "3.9", "3.10" ] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install poetry | |
run: pip install poetry | |
- name: Install dependencies | |
run: poetry install | |
- name: Run type checker | |
run: poetry run mypy . | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: [ "3.9", "3.10" ] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install poetry | |
run: pip install poetry | |
- name: Install dependencies | |
run: poetry install | |
- name: Run tests | |
run: poetry run python -m pytest --cov=./ | |
- name: Prepare coverage report | |
run: poetry run python -m coverage xml -i | |
- name: Codecov | |
uses: codecov/codecov-action@v1.5.0 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
fail_ci_if_error: true |