|
12 | 12 | - master |
13 | 13 |
|
14 | 14 | jobs: |
15 | | - test: |
| 15 | + unit-test: |
| 16 | + runs-on: ubuntu-latest |
| 17 | + steps: |
| 18 | + - uses: actions/checkout@v3 |
| 19 | + - name: Set up Python 3.10 |
| 20 | + uses: actions/setup-python@v4 |
| 21 | + with: |
| 22 | + python-version: "3.10" |
| 23 | + - name: Install dependencies |
| 24 | + run: | |
| 25 | + python -m pip install --upgrade pip |
| 26 | + pip install -e .[test] |
| 27 | + pre-commit install |
| 28 | + pre-commit autoupdate |
| 29 | + - name: Lint with precommit checks |
| 30 | + run: | |
| 31 | + pre-commit run --all-files |
| 32 | + - name: Test with Pytest |
| 33 | + run: | |
| 34 | + pytest \ |
| 35 | + --junitxml=junit/test-results.xml \ |
| 36 | + --cov-report=xml --cov=carsons \ |
| 37 | + tests/ |
| 38 | + - name: Make coverage file |
| 39 | + run: | |
| 40 | + coverage xml |
| 41 | + - uses: codecov/codecov-action@v3 |
| 42 | + with: |
| 43 | + files: ./coverage.xml # optional |
| 44 | + flags: unittests # optional |
| 45 | + name: codecov-umbrella # optional |
| 46 | + fail_ci_if_error: true # optional (default = false) |
| 47 | + verbose: true # optional (default = false) |
| 48 | + |
| 49 | + compatibility: |
| 50 | + needs: unit-test |
16 | 51 | runs-on: ubuntu-latest |
17 | 52 | strategy: |
18 | 53 | fail-fast: false |
19 | 54 | matrix: |
20 | | - python-version: [3.6, 3.7, 3.8, 3.9] |
| 55 | + python-version: ["3.7", "3.8", "3.9", "3.11", pypy3.8, pypy3.9] |
| 56 | + # skipping 3.10 since the unit-test job runs against it |
21 | 57 | steps: |
22 | | - - uses: actions/checkout@v2 |
| 58 | + - uses: actions/checkout@v3 |
23 | 59 | - name: Set up Python ${{ matrix.python-version }} |
24 | | - uses: actions/setup-python@v2 |
| 60 | + uses: actions/setup-python@v4 |
25 | 61 | with: |
26 | 62 | python-version: ${{ matrix.python-version }} |
27 | 63 | - name: Install dependencies |
28 | 64 | run: | |
29 | 65 | python -m pip install --upgrade pip |
30 | 66 | pip install -e .[test] |
31 | | - - name: Lint with flake8 |
32 | | - run: | |
33 | | - flake8 |
34 | 67 | - name: Test with Pytest |
35 | 68 | run: | |
36 | | - pytest \ |
37 | | - --junitxml=junit/test-results.xml \ |
38 | | - --mypy \ |
39 | | - --cov-report term-missing --cov-report=xml --cov-report=html --cov=carsons \ |
40 | | - tests/ |
| 69 | + pytest |
0 commit comments