Skip to content

Commit

Permalink
workflows: fix no markers on schedule
Browse files Browse the repository at this point in the history
Markers on schedule need to evaluate to empty string.

Signed-off-by: Giacomo Dematteis <[email protected]>
  • Loading branch information
DematteisGiacomo committed Nov 29, 2024
1 parent 042023d commit 42deb37
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/on_target.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,14 @@ jobs:
working-directory: thingy91x-oob/tests/on_target
run: |
mkdir -p results
pytest -v ${{ inputs.pytest_marker }} \
if [ "${{ inputs.pytest_marker }}" == "no_markers_flag" ]; then
real_pytest_marker=""
else
real_pytest_marker="${{ inputs.pytest_marker }}"
fi
pytest -v $real_pytest_marker \
--junit-xml=results/test-results.xml \
--html=results/test-results.html --self-contained-html \
${{ inputs.pytest_path }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
default: -m "not slow"

schedule:
- cron: "0 0 * * *"
- cron: "50 13 * * *"
push:
branches:
- main
Expand All @@ -35,4 +35,4 @@ jobs:
with:
artifact_fw_version: ${{ needs.build.outputs.version }}
artifact_run_id: ${{ needs.build.outputs.run_id }}
pytest_marker: ${{ inputs.pytest_marker || (github.event_name == 'schedule' && '') || (github.event_name == 'push' && '-m "not slow"') }}
pytest_marker: ${{ inputs.pytest_marker || (github.event_name == 'schedule' && 'no_markers_flag') || (github.event_name == 'push' && '-m "not slow"') }}

0 comments on commit 42deb37

Please sign in to comment.