[PATCH kvm-unit-tests 07/12] scripts/runtime: change callsite of $TEST_DIR/run

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



$TEST_DIR/run doesn't exist for standalone tests, they use
$RUNTIME_arch_run in its place.

Signed-off-by: Radim Krčmář <rkrcmar@xxxxxxxxxx>
---
 run_tests.sh         | 2 ++
 scripts/runtime.bash | 6 ++++--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/run_tests.sh b/run_tests.sh
index 2549679e653b..b488949d219b 100755
--- a/run_tests.sh
+++ b/run_tests.sh
@@ -6,6 +6,8 @@ if [ ! -f config.mak ]; then
 fi
 source config.mak
 source scripts/functions.bash
+
+RUNTIME_arch_run="./$TEST_DIR/run >> test.log"
 source scripts/runtime.bash
 
 config=$TEST_DIR/unittests.cfg
diff --git a/scripts/runtime.bash b/scripts/runtime.bash
index 8813b9ddbf1e..defbef31377d 100644
--- a/scripts/runtime.bash
+++ b/scripts/runtime.bash
@@ -1,3 +1,5 @@
+[ "${RUNTIME_arch_run?}" ]
+
 qemu=${QEMU:-qemu-system-$ARCH}
 verbose=0
 
@@ -37,14 +39,14 @@ function run()
         fi
     done
 
-    cmdline="TESTNAME=$testname ACCEL=$accel ./$TEST_DIR-run $kernel -smp $smp $opts"
+    cmdline="TESTNAME=$testname ACCEL=$accel $RUNTIME_arch_run $kernel -smp $smp $opts"
     if [ $verbose != 0 ]; then
         echo $cmdline
     fi
 
     # extra_params in the config file may contain backticks that need to be
     # expanded, so use eval to start qemu
-    eval $cmdline >> test.log
+    eval $cmdline
 
     if [ $? -le 1 ]; then
         echo -e "\e[32mPASS\e[0m $1"
-- 
2.7.0

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux