Skip to content

Commit ba72a0b

Browse files
tests_ on_target: fix nightly
Fix for nightly. Signed-off-by: Giacomo Dematteis <giacomo.dematteis@nordicsemi.no>
1 parent 144ac98 commit ba72a0b

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

.github/workflows/target-test.yml

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -41,16 +41,16 @@ jobs:
4141
target_test:
4242
# This will create multiple jobs, one for each target defined in the matrix
4343
strategy:
44+
fail-fast: false # Don't fail all jobs if one fails
4445
matrix:
4546
include:
4647
- device: cia-trd-thingy91x
4748
- device: ppk_thingy91x
48-
# Only run PPK tests when slow marker is specified
49-
if: ${{ inputs.pytest_marker == 'slow' }}
5049

5150
# Self-hosted runner is labeled according to the device it is linked with
5251
runs-on: ${{ matrix.device }}
5352
name: Target Test - ${{ matrix.device }}
53+
continue-on-error: true # Allow this job to fail without failing the whole workflow
5454

5555
permissions:
5656
actions: read
@@ -112,23 +112,24 @@ jobs:
112112
run: |
113113
mkdir -p results
114114
115+
if [[ '${{ inputs.pytest_marker }}' == 'no_markers_flag' || '${{ inputs.pytest_marker }}' == '' ]]; then
116+
pytest_marker_arg=()
117+
else
118+
pytest_marker_arg=(-m "${{ inputs.pytest_marker }}")
119+
fi
120+
echo pytest -v "${pytest_marker_arg[@]}"
121+
115122
if [[ '${{ matrix.device }}' == 'ppk_thingy91x' ]]; then
116123
# For PPK device, only run test_power.py
117-
pytest -v tests/test_ppk/test_power.py \
124+
pytest -v "${pytest_marker_arg[@]}" \
118125
--junit-xml=results/test-results.xml \
119-
--html=results/test-results.html --self-contained-html
126+
--html=results/test-results.html --self-contained-html \
127+
tests/test_ppk/test_power.py
120128
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[@]}"
129129
pytest -v "${pytest_marker_arg[@]}" \
130130
--junit-xml=results/test-results.xml \
131131
--html=results/test-results.html --self-contained-html \
132+
--ignore=tests/test_ppk \
132133
${{ inputs.pytest_path }}
133134
fi
134135
shell: bash
@@ -164,7 +165,7 @@ jobs:
164165
uses: actions/upload-artifact@v4
165166
id: artifact-report
166167
with:
167-
name: test-report
168+
name: test-report-${{ matrix.device }}
168169
path: |
169170
asset-tracker-template/tests/on_target/results/*.html
170171
@@ -173,6 +174,6 @@ jobs:
173174
uses: actions/upload-artifact@v4
174175
id: artifact-upload-test-logs
175176
with:
176-
name: test-logs
177+
name: test-logs-${{ matrix.device }}
177178
path: |
178179
asset-tracker-template/tests/on_target/outcomes/logs/*.txt

0 commit comments

Comments
 (0)