@@ -56,23 +56,18 @@ jobs:
5656 restore-keys : |
5757 pip-${{ runner.os }}-
5858 pip-
59- - name : Install apt requirements
60- run : |
61- sudo apt-get update
62- sudo apt-get install gcc libssl-dev python3-dev swig
6359 - name : Install requirements
6460 run : |
6561 pip --cache-dir=.pip install --upgrade pip
66- pip --cache-dir=.pip install pylint -r requirements.txt
67- - name : Run Pylint
68- run : pylint startup tests ./*.py 2>&1 | tee pylint.txt
69- working-directory : ${{ github.workspace }}
62+ pip --cache-dir=.pip install -r requirements.txt
63+ - name : Lint with ruff
64+ uses : astral-sh/ruff-action@v4.1.0
65+ args : check --exit-zero
7066 - name : Upload results
7167 uses : actions/upload-artifact@v7
7268 with :
7369 name : Lint
74- path : |
75- ${{ github.workspace }}/pylint.txt
70+ path : ruff.txt
7671 if-no-files-found : error
7772 sast :
7873 # The SAST scanner action is based on Docker, and therefore does not work on ubuntu-slim.
@@ -114,27 +109,21 @@ jobs:
114109 sudo apt-get update
115110 sudo apt-get install -y bleachbit chkrootkit fwupd rkhunter modemmanager
116111 pip --cache-dir=.pip install --upgrade pip
117- pip --cache-dir=.pip install coverage
118112 pip --cache-dir=.pip install -r requirements.txt
119- - name : Run tests with coverage
120- run : coverage run
121- working-directory : ${{ github.workspace }}
122- - name : Create coverage reports
113+ - name : Run tests
123114 run : |
124- coverage report | tee coverage.txt
125- coverage html
126- coverage xml
127- coverage json
128- working-directory : ${{ github.workspace }}
115+ set -o pipefail
116+ pytest | tee test-output.txt
129117 - name : Upload results
130118 uses : actions/upload-artifact@v7
131119 with :
132120 name : Coverage
133121 path : |
134- ${{ github.workspace }}/coverage.txt
135- ${{ github.workspace }}/coverage.xml
136- ${{ github.workspace }}/coverage.json
137- ${{ github.workspace }}/htmlcov
122+ .test_durations
123+ coverage.xml
124+ coverage.json
125+ htmlcov
126+ test-output.txt
138127 if-no-files-found : error
139128 - name : Upload results to Codecov
140129 uses : codecov/codecov-action@v7
0 commit comments