drm/ci: generate testlist from build

Stop vendoring the testlist into the kernel. Instead, use the
testlist from the IGT build to ensure we do not miss renamed
or newly added tests.

Signed-off-by: Vignesh Raman <vignesh.raman@collabora.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Jessica Zhang <quic_jesszhan@quicinc.com>
Acked-by: Helen Koike <helen.koike@collabora.com>
Signed-off-by: Helen Koike <helen.koike@collabora.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240529024049.356327-4-vignesh.raman@collabora.com
This commit is contained in:
Vignesh Raman
2024-05-29 08:10:46 +05:30
committed by Helen Koike
parent 9c5219349b
commit 0493be3ba1
3 changed files with 40 additions and 2765 deletions

View File

@@ -3,6 +3,30 @@
set -ex
function generate_testlist {
set +x
while read -r line; do
if [ "$line" = "TESTLIST" ] || [ "$line" = "END TESTLIST" ]; then
continue
fi
tests=$(echo "$line" | tr ' ' '\n')
for test in $tests; do
output=$(/igt/libexec/igt-gpu-tools/"$test" --list-subtests || true)
if [ -z "$output" ]; then
echo "$test"
else
echo "$output" | while read -r subtest; do
echo "$test@$subtest"
done
fi
done
done < /igt/libexec/igt-gpu-tools/test-list.txt > /igt/libexec/igt-gpu-tools/ci-testlist.txt
set -x
}
git clone https://gitlab.freedesktop.org/drm/igt-gpu-tools.git --single-branch --no-checkout
cd igt-gpu-tools
git checkout $IGT_VERSION
@@ -26,6 +50,17 @@ meson build $MESON_OPTIONS $EXTRA_MESON_ARGS
ninja -C build -j${FDO_CI_CONCURRENT:-4} || ninja -C build -j 1
ninja -C build install
if [[ "$KERNEL_ARCH" = "arm64" ]]; then
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/igt/lib/aarch64-linux-gnu
elif [[ "$KERNEL_ARCH" = "arm" ]]; then
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/igt/lib
else
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/igt/lib64
fi
echo "Generating ci-testlist.txt"
generate_testlist
mkdir -p artifacts/
tar -cf artifacts/igt.tar /igt

View File

@@ -59,25 +59,26 @@ fi
curl -L --retry 4 -f --retry-all-errors --retry-delay 60 -s ${FDO_HTTP_CACHE_URI:-}$PIPELINE_ARTIFACTS_BASE/$ARCH/igt.tar.gz | tar --zstd -v -x -C /
TESTLIST="/igt/libexec/igt-gpu-tools/ci-testlist.txt"
# If the job is parallel at the gitab job level, take the corresponding fraction
# of the caselist.
if [ -n "$CI_NODE_INDEX" ]; then
sed -ni $CI_NODE_INDEX~$CI_NODE_TOTAL"p" /install/testlist.txt
sed -ni $CI_NODE_INDEX~$CI_NODE_TOTAL"p" $TESTLIST
fi
# core_getversion checks if the driver is loaded and probed correctly
# so run it in all shards
if ! grep -q "core_getversion" /install/testlist.txt; then
if ! grep -q "core_getversion" $TESTLIST; then
# Add the line to the file
echo "core_getversion" >> /install/testlist.txt
echo "core_getversion" >> $TESTLIST
fi
set +e
igt-runner \
run \
--igt-folder /igt/libexec/igt-gpu-tools \
--caselist /install/testlist.txt \
--caselist $TESTLIST \
--output /results \
$IGT_SKIPS \
$IGT_FLAKES \

File diff suppressed because it is too large Load Diff