| 1 |
name: build |
| 2 |
on: |
| 3 |
push: |
| 4 |
branches: |
| 5 |
- main |
| 6 |
pull_request: |
| 7 |
branches: |
| 8 |
- main |
| 9 |
jobs: |
| 10 |
lint: |
| 11 |
name: lint |
| 12 |
runs-on: ubuntu-latest |
| 13 |
steps: |
| 14 |
- uses: actions/checkout@v3 |
| 15 |
- uses: actions/setup-python@v3 |
| 16 |
- run: python -m pip install --upgrade pip wheel |
| 17 |
- run: pip install tox tox-gh-actions |
| 18 |
- run: tox -eflake8 |
| 19 |
- run: tox -edocs |
| 20 |
tests: |
| 21 |
name: tests |
| 22 |
strategy: |
| 23 |
matrix: |
| 24 |
# TODO: add windows-latest |
| 25 |
os: [ubuntu-latest, macos-latest] |
| 26 |
python: ['3.8', '3.9', '3.10', '3.11', 'pypy-3.9'] |
| 27 |
sqla: ['sqlalchemy<2 flask-sqlalchemy<3.1', 'sqlalchemy>=2 flask-sqlalchemy>=3.1'] |
| 28 |
fail-fast: false |
| 29 |
runs-on: ${{ matrix.os }} |
| 30 |
steps: |
| 31 |
- uses: actions/checkout@v3 |
| 32 |
- uses: actions/setup-python@v3 |
| 33 |
with: |
| 34 |
python-version: ${{ matrix.python }} |
| 35 |
- run: python -m pip install --upgrade pip wheel |
| 36 |
- run: pip install tox tox-gh-actions |
| 37 |
- run: SQLALCHEMY_VERSION="${{ matrix.sqla }}" tox |