From 3da6916383afc1c8a8b59dae38c4bc02680b50ba Mon Sep 17 00:00:00 2001 From: Timothy Flynn Date: Thu, 29 Feb 2024 10:08:58 -0500 Subject: [PATCH] CI: Remove the WPT directory after tests have completed This directory is about 600MB. Remove it after running WPT as an attempt to alleviate CI disk space issues. --- Meta/Azure/Lagom.yml | 4 +--- Tests/LibWeb/WPT/run.sh | 9 +++++++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/Meta/Azure/Lagom.yml b/Meta/Azure/Lagom.yml index 7b08de404f8..ecd9c622c4f 100644 --- a/Meta/Azure/Lagom.yml +++ b/Meta/Azure/Lagom.yml @@ -173,9 +173,7 @@ jobs: - ${{ if and(eq(parameters.fuzzer, 'NoFuzz'), eq(parameters.os, 'Linux') ) }}: - script: | - du -sh /tmp* | sort -h - ./run.sh - du -sh /tmp* | sort -h + ./run.sh --remove-wpt-repository displayName: 'WPT' workingDirectory: $(Build.SourcesDirectory)/Tests/LibWeb/WPT/ env: diff --git a/Tests/LibWeb/WPT/run.sh b/Tests/LibWeb/WPT/run.sh index 6254da72ca4..8d03d483e16 100755 --- a/Tests/LibWeb/WPT/run.sh +++ b/Tests/LibWeb/WPT/run.sh @@ -14,6 +14,7 @@ fi : "${WEBDRIVER_BINARY:=$(env PATH="${SERENITY_SOURCE_DIR}/Build/lagom/bin/Ladybird.app/Contents/MacOS:${SERENITY_SOURCE_DIR}/Build/lagom/libexec:${SERENITY_SOURCE_DIR}/Meta/Lagom/Build/libexec:${PATH}" \ which WebDriver)}" update_expectations_metadata=false +remove_wpt_repository=false for arg in "$@"; do case $arg in @@ -25,6 +26,10 @@ for arg in "$@"; do update_expectations_metadata=true shift ;; + --remove-wpt-repository) + remove_wpt_repository=true + shift + ;; *) echo "Unknown argument ${arg}" exit 1 @@ -83,4 +88,8 @@ if [[ $update_expectations_metadata == true ]]; then python3 ./concat-extract-metadata.py --concat ./metadata > metadata.txt fi +if [[ $remove_wpt_repository == true ]]; then + rm -rf wpt +fi + popd