Skip to content

Commit 36c48ea

Browse files
panvatargos
authored andcommitted
tools: add daily WPT Report workflow step summary
PR-URL: #46763 Reviewed-By: Yagiz Nizipli <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]>
1 parent 12a5618 commit 36c48ea

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

.github/workflows/daily-wpt-fyi.yml

+12-2
Original file line numberDiff line numberDiff line change
@@ -134,11 +134,21 @@ jobs:
134134
working-directory: out/wpt
135135
run: |
136136
gzip wptreport.json
137+
echo "## Node.js ${{ steps.setup-node.outputs.node-version }}" >> $GITHUB_STEP_SUMMARY
137138
for WPT_FYI_ENDPOINT in "https://wpt.fyi/api/results/upload" "https://staging.wpt.fyi/api/results/upload"
138139
do
139-
curl \
140+
response=$(curl -sS \
140141
-u "$WPT_FYI_USERNAME:$WPT_FYI_PASSWORD" \
141142
142143
-F "labels=master" \
143-
$WPT_FYI_ENDPOINT
144+
$WPT_FYI_ENDPOINT)
145+
146+
if [[ $response =~ Task\ ([0-9]+)\ added\ to\ queue ]]; then
147+
run_id=${BASH_REMATCH[1]}
148+
origin=${WPT_FYI_ENDPOINT%/api/results/upload}
149+
150+
echo "" >> $GITHUB_STEP_SUMMARY
151+
echo "Run ID [$run_id]($origin/api/runs/$run_id) added to the processor queue at $origin" >> $GITHUB_STEP_SUMMARY
152+
echo "- [View on the ${origin:8} dashboard]($origin/results?run_id=$run_id)" >> $GITHUB_STEP_SUMMARY
153+
fi
144154
done

0 commit comments

Comments
 (0)