Drop support for Python 2 and Python < 3.6
[dotbot.git] / .github / workflows / build.yml
blobe826947ca2b08bcc06710d173b4b2ef9afa3d21d
1 name: CI
2 on:
3   push:
4   pull_request:
5   schedule:
6     - cron: '0 8 * * 6'
7 jobs:
8   test:
9     env:
10       PIP_DISABLE_PIP_VERSION_CHECK: 1
11     strategy:
12       fail-fast: false
13       matrix:
14         os: ["ubuntu-20.04", "macos-latest"]
15         python: ["3.6", "3.7", "3.8", "3.9", "3.10", "pypy-3.9"]
16         include:
17           - os: "windows-latest"
18             python: "3.8"
19           - os: "windows-latest"
20             python: "3.9"
21           - os: "windows-latest"
22             python: "3.10"
23     runs-on: ${{ matrix.os }}
24     name: "Test: Python ${{ matrix.python }} on ${{ matrix.os }}"
25     steps:
26       - uses: actions/checkout@v3
27         with:
28           submodules: recursive
29       - uses: actions/setup-python@v4
30         with:
31           python-version: ${{ matrix.python }}
32       - name: "Install dependencies"
33         run: |
34           python -m pip install --upgrade pip setuptools
35           python -m pip install tox tox-gh-actions
36       - name: "Run tests"
37         run: |
38           python -m tox
39           python -m tox -e coverage_report
40       - uses: codecov/codecov-action@v3
41   fmt:
42     name: Format
43     runs-on: ubuntu-22.04
44     steps:
45       - uses: actions/checkout@v3
46       - uses: psf/black@stable
47       - uses: isort/isort-action@v1