ci: deduplicate constructing the ARTIFACTS_BASE_URL
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26670>
This commit is contained in:

committed by
Marge Bot

parent
d024da3900
commit
e46702f7ae
@@ -84,6 +84,7 @@ variables:
|
||||
# Disable farm with `git mv .ci-farms{,-disabled}/$farm_name`
|
||||
# Re-enable farm with `git mv .ci-farms{-disabled,}/$farm_name`
|
||||
# NEVER MIX FARM MAINTENANCE WITH ANY OTHER CHANGE IN THE SAME MERGE REQUEST!
|
||||
ARTIFACTS_BASE_URL: https://${CI_PROJECT_ROOT_NAMESPACE}.${$CI_PAGES_DOMAIN}/-/${CI_PROJECT_NAME}/-/jobs/${CI_JOB_ID}/artifacts
|
||||
|
||||
default:
|
||||
before_script:
|
||||
|
@@ -2,6 +2,7 @@
|
||||
|
||||
for var in \
|
||||
ACO_DEBUG \
|
||||
ARTIFACTS_BASE_URL \
|
||||
ASAN_OPTIONS \
|
||||
BASE_SYSTEM_FORK_HOST_PREFIX \
|
||||
BASE_SYSTEM_MAINLINE_HOST_PREFIX \
|
||||
|
@@ -230,7 +230,7 @@ deqp-runner junit \
|
||||
--results $RESULTS/failures.csv \
|
||||
--output $RESULTS/junit.xml \
|
||||
--limit 50 \
|
||||
--template "See https://$CI_PROJECT_ROOT_NAMESPACE.pages.freedesktop.org/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/results/{{testcase}}.xml"
|
||||
--template "See $ARTIFACTS_BASE_URL/results/{{testcase}}.xml"
|
||||
|
||||
# Report the flakes to the IRC channel for monitoring (if configured):
|
||||
if [ -n "$FLAKES_CHANNEL" ]; then
|
||||
|
@@ -55,7 +55,7 @@ deqp-runner junit \
|
||||
--results $RESULTS/failures.csv \
|
||||
--output $RESULTS/junit.xml \
|
||||
--limit 50 \
|
||||
--template "See https://$CI_PROJECT_ROOT_NAMESPACE.pages.freedesktop.org/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/results/{{testcase}}.xml"
|
||||
--template "See $ARTIFACTS_BASE_URL/results/{{testcase}}.xml"
|
||||
|
||||
# Report the flakes to the IRC channel for monitoring (if configured):
|
||||
if [ -n "$FLAKES_CHANNEL" ]; then
|
||||
|
@@ -458,10 +458,8 @@ class LAVAJobSubmitter(PathResolver):
|
||||
self.finish_script(last_attempt_job)
|
||||
|
||||
def print_log_artifact_url(self):
|
||||
base_url = "https://$CI_PROJECT_ROOT_NAMESPACE.pages.freedesktop.org/"
|
||||
artifacts_path = "-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/"
|
||||
relative_log_path = self.structured_log_file.relative_to(pathlib.Path.cwd())
|
||||
full_path = f"{base_url}{artifacts_path}{relative_log_path}"
|
||||
full_path = f"$ARTIFACTS_BASE_URL/{relative_log_path}"
|
||||
artifact_url = path.expandvars(full_path)
|
||||
|
||||
print_log(f"Structural Logging data available at: {artifact_url}")
|
||||
|
@@ -106,7 +106,7 @@ deqp-runner junit \
|
||||
--results $RESULTS/failures.csv \
|
||||
--output $RESULTS/junit.xml \
|
||||
--limit 50 \
|
||||
--template "See https://$CI_PROJECT_ROOT_NAMESPACE.pages.freedesktop.org/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/results/{{testcase}}.xml"
|
||||
--template "See $ARTIFACTS_BASE_URL/results/{{testcase}}.xml"
|
||||
|
||||
# Report the flakes to the IRC channel for monitoring (if configured):
|
||||
if [ -n "$FLAKES_CHANNEL" ]; then
|
||||
|
@@ -190,8 +190,6 @@ then
|
||||
printf "%s\n" "Found $(cat /tmp/version.txt), expected $MESA_VERSION"
|
||||
fi
|
||||
|
||||
ARTIFACTS_BASE_URL="https://${CI_PROJECT_ROOT_NAMESPACE}.${CI_PAGES_DOMAIN}/-/${CI_PROJECT_NAME}/-/jobs/${CI_JOB_ID}/artifacts"
|
||||
|
||||
./piglit summary aggregate "$RESULTS" -o junit.xml
|
||||
|
||||
PIGLIT_RESULTS="${PIGLIT_RESULTS:-replay}"
|
||||
|
@@ -27,7 +27,7 @@ deqp-runner suite --suite $($suite) `
|
||||
$jobs
|
||||
$deqpstatus = $?
|
||||
|
||||
$template = "See https://$($env:CI_PROJECT_ROOT_NAMESPACE).pages.freedesktop.org/-/$($env:CI_PROJECT_NAME)/-/jobs/$($env:CI_JOB_ID)/artifacts/results/{{testcase}}.xml"
|
||||
$template = "See $($env:ARTIFACTS_BASE_URL)/results/{{testcase}}.xml"
|
||||
deqp-runner junit --testsuite dEQP --results "$($results)/failures.csv" --output "$($results)/junit.xml" --limit 50 --template $template
|
||||
Copy-Item -Path "C:\deqp\testlog.css" -Destination $($results)
|
||||
Copy-Item -Path "C:\deqp\testlog.xsl" -Destination $($results)
|
||||
|
Reference in New Issue
Block a user