@@ -41,12 +41,11 @@ jobs:
41
41
target_test :
42
42
# This will create multiple jobs, one for each target defined in the matrix
43
43
strategy :
44
+ fail-fast : false # Don't fail all jobs if one fails
44
45
matrix :
45
46
include :
46
47
- device : cia-trd-thingy91x
47
48
- device : ppk_thingy91x
48
- # Only run PPK tests when slow marker is specified
49
- if : ${{ inputs.pytest_marker == 'slow' }}
50
49
51
50
# Self-hosted runner is labeled according to the device it is linked with
52
51
runs-on : ${{ matrix.device }}
@@ -112,23 +111,24 @@ jobs:
112
111
run : |
113
112
mkdir -p results
114
113
114
+ if [[ '${{ inputs.pytest_marker }}' == 'no_markers_flag' || '${{ inputs.pytest_marker }}' == '' ]]; then
115
+ pytest_marker_arg=()
116
+ else
117
+ pytest_marker_arg=(-m "${{ inputs.pytest_marker }}")
118
+ fi
119
+ echo pytest -v "${pytest_marker_arg[@]}"
120
+
115
121
if [[ '${{ matrix.device }}' == 'ppk_thingy91x' ]]; then
116
122
# For PPK device, only run test_power.py
117
- pytest -v tests/test_ppk/test_power.py \
123
+ pytest -v "${pytest_marker_arg[@]}" \
118
124
--junit-xml=results/test-results.xml \
119
- --html=results/test-results.html --self-contained-html
125
+ --html=results/test-results.html --self-contained-html \
126
+ tests/test_ppk/test_power.py
120
127
else
121
- # For other devices, use normal marker logic
122
- if [[ '${{ inputs.pytest_marker }}' == 'no_markers_flag' || '${{ inputs.pytest_marker }}' == '' ]]; then
123
- pytest_marker_arg=()
124
- else
125
- pytest_marker_arg=(-m "${{ inputs.pytest_marker }}")
126
- fi
127
-
128
- echo pytest -v "${pytest_marker_arg[@]}"
129
128
pytest -v "${pytest_marker_arg[@]}" \
130
129
--junit-xml=results/test-results.xml \
131
130
--html=results/test-results.html --self-contained-html \
131
+ --ignore=tests/test_ppk \
132
132
${{ inputs.pytest_path }}
133
133
fi
134
134
shell : bash
@@ -164,7 +164,7 @@ jobs:
164
164
uses : actions/upload-artifact@v4
165
165
id : artifact-report
166
166
with :
167
- name : test-report
167
+ name : test-report-${{ matrix.device }}
168
168
path : |
169
169
asset-tracker-template/tests/on_target/results/*.html
170
170
@@ -173,6 +173,6 @@ jobs:
173
173
uses : actions/upload-artifact@v4
174
174
id : artifact-upload-test-logs
175
175
with :
176
- name : test-logs
176
+ name : test-logs-${{ matrix.device }}
177
177
path : |
178
178
asset-tracker-template/tests/on_target/outcomes/logs/*.txt
0 commit comments