Skip to content

Commit 8212e03

Browse files
committed
Update: testing keeping only sqlite results
1 parent cf77c9c commit 8212e03

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

‎.github/workflows/testing.yml‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,24 @@ jobs:
1414
uses: wp-cli/.github/.github/workflows/reusable-testing.yml@main
1515
with:
1616
minimum-php: "7.4"
17+
filter-sqlite:
18+
needs: test
19+
runs-on: ubuntu-latest
20+
if: always()
21+
steps:
22+
- name: Filter SQLite jobs
23+
run: |
24+
sqlite_jobs=$(echo '${{ toJson(needs.test.result) }}' | jq 'to_entries | map(select(.key | contains("sqlite"))) | from_entries')
25+
echo "SQLite job results: $sqlite_jobs"
26+
if echo "$sqlite_jobs" | jq -e 'has("failure")'; then
27+
echo "Some SQLite jobs failed"
28+
exit 1
29+
elif echo "$sqlite_jobs" | jq -e 'has("cancelled")'; then
30+
echo "Some SQLite jobs were cancelled"
31+
exit 1
32+
elif [ "$(echo "$sqlite_jobs" | jq 'length')" -eq "0" ]; then
33+
echo "No SQLite jobs were run"
34+
exit 1
35+
else
36+
echo "All SQLite jobs passed"
37+
fi

0 commit comments

Comments
 (0)