Files
xen/automation/scripts/qemu-smoke-x86-64.sh
T
Roger Pau Monne ea6a2c4b77 automation: increase tests maximum time from 10s to 30s
10s is too low for the clang tests, this is the output from a clang
test:

  (XEN) [    6.512748] ***************************************************
  (XEN) [    6.513323] SELFTEST FAILURE: CORRECT BEHAVIOR CANNOT BE GUARANTEED
  (XEN) [    6.513891] ***************************************************
  (XEN) [    6.514469] 3... 2... 1...
  (XEN) [    9.520011] *** Serial input to DOM0 (type 'CTRL-a' three times to switch input)
  (XEN) [    9.544319] Freed 488kB init memory
  --- Xen Test Framework ---
  Environment: HVM 32bit (PAE 3 levels)
  Hello World
  Test result: SUCCESS
  (XEN) [    9.610977] Hardware Dom0 halted: halting machine

As can be seen from the output above booting Xen and the XTF test
takes ~10s, without accounting for the time it takes for QEMU to
initialize.

Increase the timeout to 30s to be on the safe side.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Wei Liu <wl@xen.org>
Release-acked-by: Juergen Gross <jgross@suse.com>
2019-12-03 13:57:28 +00:00

33 lines
802 B
Bash
Executable File

#!/bin/bash
set -ex
# variant should be either pv or pvh
variant=$1
# Install QEMU
export DEBIAN_FRONTENT=noninteractive
apt-get -qy update
apt-get -qy install qemu-system-x86
# Clone and build XTF
git clone https://xenbits.xen.org/git-http/xtf.git
cd xtf && make -j$(nproc) && cd -
case $variant in
pvh) k=test-hvm32pae-example extra="dom0-iommu=none dom0=pvh" ;;
*) k=test-pv32pae-example extra= ;;
esac
rm -f smoke.serial
set +e
timeout -k 1 30 \
qemu-system-x86_64 -nographic -kernel binaries/xen \
-initrd xtf/tests/example/$k \
-append "loglvl=all com1=115200,,8n1 console=com1 noreboot \
console_timestamps=boot $extra" \
-m 512 -monitor none -serial file:smoke.serial
set -e
grep -q 'Test result: SUCCESS' smoke.serial || exit 1
exit 0