|
1 | 1 | name: Tests |
2 | 2 |
|
3 | | -on: |
4 | | - push |
| 3 | +on: push |
5 | 4 |
|
6 | 5 | jobs: |
7 | 6 | build: |
8 | | - |
9 | 7 | runs-on: ${{ matrix.os }} |
10 | 8 | strategy: |
11 | 9 | matrix: |
12 | 10 | os: [macos-latest, ubuntu-latest, windows-latest] |
13 | | - python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13'] |
| 11 | + python-version: |
| 12 | + ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14", "3.14t"] |
14 | 13 |
|
15 | 14 | steps: |
16 | | - - uses: actions/checkout@v2 |
17 | | - - name: Set up Python ${{ matrix.python-version }} |
18 | | - uses: actions/setup-python@v3 |
19 | | - with: |
| 15 | + - uses: actions/checkout@v4 |
| 16 | + - name: Set up Python ${{ matrix.python-version }} |
| 17 | + uses: actions/setup-python@v5 |
| 18 | + with: |
20 | 19 | python-version: ${{ matrix.python-version }} |
21 | 20 |
|
22 | | - - name: Install the library |
23 | | - shell: bash |
24 | | - run: pip install . |
25 | | - |
26 | | - - name: Install dependencies |
27 | | - shell: bash |
28 | | - run: pip install -r requirements_dev.txt |
29 | | - |
30 | | - - name: Print all libs |
31 | | - shell: bash |
32 | | - run: pip list |
33 | | - |
34 | | - - name: Run tests and show coverage on the command line |
35 | | - run: coverage run --source=displayhooks --omit="*tests*" -m pytest --cache-clear --assert=plain && coverage report -m --fail-under=100 |
36 | | - |
37 | | - - name: Upload reports to codecov |
38 | | - env: |
39 | | - CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}} |
40 | | - if: runner.os == 'Linux' |
41 | | - run: | |
42 | | - curl -Os https://uploader.codecov.io/latest/linux/codecov |
43 | | - find . -iregex "codecov.*" |
44 | | - chmod +x codecov |
45 | | - ./codecov -t ${CODECOV_TOKEN} |
46 | | -
|
47 | | - - name: Run tests and show the branch coverage on the command line |
48 | | - run: coverage run --branch --source=displayhooks --omit="*tests*" -m pytest --cache-clear --assert=plain && coverage report -m --fail-under=100 |
| 21 | + - name: Install the library |
| 22 | + shell: bash |
| 23 | + run: pip install . |
| 24 | + |
| 25 | + - name: Install dependencies |
| 26 | + shell: bash |
| 27 | + run: pip install -r requirements_dev.txt |
| 28 | + |
| 29 | + - name: Print all libs |
| 30 | + shell: bash |
| 31 | + run: pip list |
| 32 | + |
| 33 | + - name: Run tests and show coverage on the command line |
| 34 | + run: | |
| 35 | + coverage run --source=displayhooks --omit="*tests*" -m pytest --cache-clear --assert=plain && coverage report -m --fail-under=100 |
| 36 | + coverage xml |
| 37 | +
|
| 38 | + - name: Upload coverage to Coveralls |
| 39 | + if: runner.os == 'Linux' |
| 40 | + env: |
| 41 | + COVERALLS_REPO_TOKEN: ${{secrets.COVERALLS_REPO_TOKEN}} |
| 42 | + uses: coverallsapp/github-action@v2 |
| 43 | + with: |
| 44 | + format: cobertura |
| 45 | + file: coverage.xml |
| 46 | + |
| 47 | + - name: Run tests and show the branch coverage on the command line |
| 48 | + run: coverage run --branch --source=displayhooks --omit="*tests*" -m pytest --cache-clear --assert=plain && coverage report -m --fail-under=100 |
0 commit comments