ci: Allow specifying any shell command via HWCI_TEST_SCRIPT

Interpret the value of HWCI_TEST_SCRIPT environment variable as a shell
command. This allows, for example, to provide additional environment
variables: HWCI_TEST_SCRIPT="VAR1=VAL1 VAR2=VAL2 /path/to/script"

Additionally, add the missing execute permission flags to
gtest-runner.sh script.

Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Reviewed-by: Guilherme Gallo <guilherme.gallo@collabora.com>
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15208>
This commit is contained in:
Cristian Ciocaltea 2022-02-23 20:29:24 +02:00 committed by Marge Bot
parent fb2ffc2f67
commit 356c9c25c3
2 changed files with 1 additions and 1 deletions

View File

@ -91,7 +91,7 @@ if [ -n "$HWCI_START_XORG" ]; then
export DISPLAY=:0
fi
sh "$HWCI_TEST_SCRIPT" && RESULT=pass || RESULT=fail
sh -c "$HWCI_TEST_SCRIPT" && RESULT=pass || RESULT=fail
# Let's make sure the results are always stored in current working directory
mv -f ${CI_PROJECT_DIR}/results ./ 2>/dev/null || true

0
.gitlab-ci/gtest-runner.sh Normal file → Executable file
View File