2021-02-17 16:22:05 +00:00
|
|
|
name: CI
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2021-09-10 10:39:50 +00:00
|
|
|
branches: [ main ]
|
2021-02-17 16:22:05 +00:00
|
|
|
pull_request:
|
2021-09-10 10:39:50 +00:00
|
|
|
branches: [ main ]
|
2021-02-17 16:22:05 +00:00
|
|
|
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
lint:
|
|
|
|
name: "Lint & Packaging"
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- uses: "actions/setup-python@v2"
|
|
|
|
with:
|
|
|
|
python-version: "3.6"
|
|
|
|
|
|
|
|
- name: "Install dependencies"
|
|
|
|
run: |
|
|
|
|
set -xe
|
|
|
|
python -VV
|
|
|
|
python -m site
|
|
|
|
python -m pip install --upgrade pip setuptools wheel
|
|
|
|
python -m pip install --upgrade tox
|
|
|
|
- name: "Run tox lint targets for ${{ matrix.python-version }}"
|
|
|
|
run: "python -m tox -e check_isort,pep8,packaging"
|
|
|
|
|
|
|
|
tests:
|
|
|
|
needs: lint
|
|
|
|
name: "Python ${{ matrix.python-version }}"
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
python-version: ["3.6", "3.7", "3.8", "3.9"]
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- uses: "actions/setup-python@v2"
|
|
|
|
with:
|
|
|
|
python-version: "${{ matrix.python-version }}"
|
|
|
|
|
|
|
|
- name: "Install dependencies"
|
|
|
|
run: |
|
|
|
|
set -xe
|
|
|
|
python -VV
|
|
|
|
python -m site
|
|
|
|
python -m pip install --upgrade pip setuptools wheel
|
|
|
|
python -m pip install --upgrade tox
|
|
|
|
- name: "Run tox targets for ${{ matrix.python-version }}"
|
|
|
|
run: "python -m tox -e py"
|