ci: correct the trace image URLs in the piglit summary

Fixes: 09429fa85b ("ci: add piglit replay jobs and remove tracie ones")
Signed-off-by: Andres Gomez <agomez@igalia.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8531>
This commit is contained in:
Andres Gomez 2021-01-16 02:46:54 +02:00 committed by Marge Bot
parent 27f8c46648
commit 0773cd33c2
2 changed files with 3 additions and 3 deletions

View File

@ -1038,7 +1038,7 @@ meson-mingw32-x86_64:
PIGLIT_PROFILES: replay
PIGLIT_REPLAY_UPLOAD_TO_MINIO: 1
PIGLIT_REPLAY_EXTRA_ARGS: --keep-image --db-path ${CI_PROJECT_DIR}/replayer-db/
PIGLIT_REPLAY_REFERENCE_IMAGES_BASE_URL: "/mesa-tracie-results/$CI_PROJECT_PATH"
PIGLIT_REPLAY_REFERENCE_IMAGES_BASE_URL: "/mesa-tracie-results/$FDO_UPSTREAM_REPO"
PIGLIT_REPLAY_ARTIFACTS_BASE_URL: "/artifacts/$CI_PROJECT_PATH/$CI_PIPELINE_ID/$CI_JOB_ID"
PIGLIT_HTML_SUMMARY: 0
PIGLIT_JUNIT_RESULTS: 1

View File

@ -202,9 +202,9 @@ if [ ${PIGLIT_HTML_SUMMARY:-1} -eq 1 ]; then
if [ "x$PIGLIT_PROFILES" = "xreplay" ]; then
find "$OLDPWD"/summary -type f -name "*.html" -print0 \
| xargs -0 sed -i 's@<img src="file://'"${RESULTS}"'@<img src="https://'"${MINIO_HOST}${PIGLIT_REPLAY_ARTIFACTS_BASE_URL}"'@g'
| xargs -0 sed -i 's%<img src="file://'"${RESULTS}"'.*-\([0-9a-f]*\)\.png%<img src="https://'"${MINIO_HOST}${PIGLIT_REPLAY_ARTIFACTS_BASE_URL}"'/traces/\1.png%g'
find "$OLDPWD"/summary -type f -name "*.html" -print0 \
| xargs -0 sed -i 's@<img src="file://@<img src="https://'"${MINIO_HOST}${PIGLIT_REPLAY_REFERENCE_IMAGES_BASE_URL}"'/@g'
| xargs -0 sed -i 's%<img src="file://%<img src="https://'"${MINIO_HOST}${PIGLIT_REPLAY_REFERENCE_IMAGES_BASE_URL}"'/%g'
fi
fi