ci: Make a missing device name correctly bail out of deqp-runner.sh.
authorEric Anholt <eric@anholt.net>
Thu, 13 Aug 2020 22:10:18 +0000 (15:10 -0700)
committerMarge Bot <eric+marge@anholt.net>
Mon, 31 Aug 2020 17:50:30 +0000 (17:50 +0000)
If your driver is totally broken and can't even report its name, let's
stop here instead of doing a CTS run full of failure to start tests and
reporting them all missing at the end.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6324>

.gitlab-ci/deqp-runner.sh

index c81229d530da614b33ce3a16b23f7e0f75b5c4b5..8d9995ed0a32e17eaec7f7d17e67a9d58402d6db 100755 (executable)
@@ -238,7 +238,7 @@ check_vk_device_name() {
     $DEQP $DEQP_OPTIONS --deqp-case=dEQP-VK.info.device --deqp-log-filename=$RESULTS/deqp-info.qpa
     DEVICENAME=`grep deviceName $RESULTS/deqp-info.qpa | sed 's|deviceName: ||g'`
     echo "deviceName: $DEVICENAME"
-    if [ -n "$DEQP_EXPECTED_RENDERER" -a $DEVICENAME != "$DEQP_EXPECTED_RENDERER" ]; then
+    if [ -n "$DEQP_EXPECTED_RENDERER" -a "x$DEVICENAME" != "x$DEQP_EXPECTED_RENDERER" ]; then
         echo "Expected deviceName $DEQP_EXPECTED_RENDERER"
         exit 1
     fi