Skip to content

Commit f8f0042

Browse files
authored
Update unit.yml
1 parent ad87579 commit f8f0042

File tree

1 file changed

+5
-18
lines changed

1 file changed

+5
-18
lines changed

.github/workflows/unit.yml

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,41 @@
11
name: Unit
2-
32
env:
43
PYTHON_MAIN_VERSION: 3.12
5-
64
on:
75
workflow_call:
8-
96
jobs:
107
build:
118
runs-on: ${{ matrix.os }}
12-
139
strategy:
1410
matrix:
1511
os: [ubuntu-latest]
1612
python-version: ["3.11", "3.12"]
17-
1813
steps:
19-
- uses: actions/checkout@v3
20-
14+
- uses: actions/checkout@v4
2115
- name: Set up Python ${{ matrix.python-version }}
22-
uses: actions/setup-python@v2
16+
uses: actions/setup-python@v4
2317
with:
2418
python-version: ${{ matrix.python-version }}
25-
2619
- name: Install dependencies
2720
run: |
2821
bash scripts/install.sh
2922
bash scripts/install.sh test
30-
3123
- name: Lint with flake8
3224
run: |
3325
# stop the build if there are Python syntax errors or undefined names
3426
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
3527
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
3628
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
37-
3829
- name: Run tests
3930
run: |
40-
pytest -v --cov --cov-report xml tests
41-
31+
pytest -v --cov --cov-report=xml --cov-report=term tests
4232
- name: Upload coverage to Codecov
4333
if: ${{ matrix.python-version == env.PYTHON_MAIN_VERSION }}
44-
uses: codecov/codecov-action@v1
34+
uses: codecov/codecov-action@v4
4535
with:
4636
token: ${{ secrets.CODECOV_TOKEN }}
47-
files: ./coverage.xml
48-
# directory: ./coverage/reports/
37+
file: ./coverage.xml
4938
flags: unittests
50-
env_vars: OS,PYTHON
5139
name: codecov-umbrella
5240
fail_ci_if_error: true
53-
# path_to_write_report: ./coverage/codecov_report.txt
5441
verbose: true

0 commit comments

Comments
 (0)