| 1 |
name: Tests |
| 2 |
|
| 3 |
on: |
| 4 |
push: |
| 5 |
branches: |
| 6 |
- master |
| 7 |
pull_request: |
| 8 |
branches: |
| 9 |
- master |
| 10 |
|
| 11 |
jobs: |
| 12 |
test: |
| 13 |
runs-on: ubuntu-latest |
| 14 |
strategy: |
| 15 |
max-parallel: 6 |
| 16 |
matrix: |
| 17 |
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12'] |
| 18 |
steps: |
| 19 |
- uses: actions/checkout@v3 |
| 20 |
- name: Set up Python ${{ matrix.python-version }} |
| 21 |
uses: actions/setup-python@v4 |
| 22 |
with: |
| 23 |
python-version: ${{ matrix.python-version }} |
| 24 |
- name: Install dependencies |
| 25 |
run: pip install tox tox-gh-actions |
| 26 |
- name: Tests |
| 27 |
run: tox |
| 28 |
- name: Coveralls |
| 29 |
env: |
| 30 |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 31 |
COVERALLS_FLAG_NAME: python-${{ matrix.python-version }} |
| 32 |
COVERALLS_PARALLEL: true |
| 33 |
run: | |
| 34 |
pip3 install coveralls |
| 35 |
coveralls --service=github |
| 36 |
coveralls: |
| 37 |
|
| 38 |
|
| 39 |
name: coverage push |
| 40 |
needs: test |
| 41 |
runs-on: ubuntu-latest |
| 42 |
steps: |
| 43 |
- name: Set up Python 3.11 |
| 44 |
uses: actions/setup-python@v4 |
| 45 |
with: |
| 46 |
python-version: 3.11 |
| 47 |
- name: Finished |
| 48 |
run: | |
| 49 |
pip3 install coveralls |
| 50 |
coveralls --finish --service=github |
| 51 |
env: |
| 52 |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 53 |
|
| 54 |
docs: |
| 55 |
runs-on: ubuntu-latest |
| 56 |
steps: |
| 57 |
- uses: actions/checkout@v3 |
| 58 |
- name: Set up Python 3.11 |
| 59 |
uses: actions/setup-python@v4 |
| 60 |
with: |
| 61 |
python-version: 3.11 |
| 62 |
- name: Install dependencies |
| 63 |
run: pip install tox |
| 64 |
- name: Check docs |
| 65 |
run: tox -e docs |
| 66 |
|
| 67 |
formatting: |
| 68 |
runs-on: ubuntu-latest |
| 69 |
steps: |
| 70 |
- uses: actions/checkout@v3 |
| 71 |
- name: Set up Python 3.11 |
| 72 |
uses: actions/setup-python@v4 |
| 73 |
with: |
| 74 |
python-version: 3.11 |
| 75 |
- name: Install dependencies |
| 76 |
run: pip install tox |
| 77 |
- name: Check formatting |
| 78 |
run: tox -e format |
| 79 |
|
| 80 |
setuppy: |
| 81 |
runs-on: ubuntu-latest |
| 82 |
steps: |
| 83 |
- uses: actions/checkout@v3 |
| 84 |
- name: Set up Python 3.11 |
| 85 |
uses: actions/setup-python@v4 |
| 86 |
with: |
| 87 |
python-version: 3.11 |
| 88 |
- name: Install dependencies |
| 89 |
run: pip install tox |
| 90 |
- name: Check docs |
| 91 |
run: tox -e setuppy |