Make test runners support execution runtimes (#2360)

If the result of a build is not directly executable on the host
system or needs an execution runtime for any other reason (e.g.,
cross-compiled ARM binaries on Intel, emscripten-generated JS
files, binaries built with Valgrind support) then the current test
runners cannot work with them. This patch makes test runners
execute binaries via a runtime given in the `$RUNTIME` environment
variable (if it is specified).

JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu
This commit is contained in:
Akos Kiss
2018-05-29 08:22:57 +02:00
committed by yichoi
parent a509570c1d
commit 3560c60c73
4 changed files with 16 additions and 10 deletions
+2 -2
View File
@@ -65,8 +65,8 @@ UNITTEST_TEMP=`mktemp unittest-out.XXXXXXXXXX`
for unit_test in $UNITTESTS
do
cmd_line="${unit_test#$ROOT_DIR}"
$unit_test &>$UNITTEST_TEMP
cmd_line="$RUNTIME ${unit_test#$ROOT_DIR}"
$RUNTIME $unit_test &>$UNITTEST_TEMP
status_code=$?
if [ $status_code -ne 0 ]