From a9953f4c3b9fac9ec7fe76157773685f63c1f789 Mon Sep 17 00:00:00 2001 From: QC Date: Fri, 29 Aug 2014 16:39:11 +0200 Subject: [PATCH] Try to fix test on travis server. --- test/run_errormsg_test.sh | 1 + test/run_switchdialog_test.sh | 15 +++++++++------ 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/test/run_errormsg_test.sh b/test/run_errormsg_test.sh index d9ccf220..606dadf9 100755 --- a/test/run_errormsg_test.sh +++ b/test/run_errormsg_test.sh @@ -15,4 +15,5 @@ sleep 5 && DISPLAY=:200 xdotool key Return wait ${RPID} RETV=$? kill ${XPID} +sleep 1 exit ${RETV} diff --git a/test/run_switchdialog_test.sh b/test/run_switchdialog_test.sh index fc4f5f54..820937e0 100755 --- a/test/run_switchdialog_test.sh +++ b/test/run_switchdialog_test.sh @@ -1,25 +1,28 @@ #!/usr/bin/env bash # Create fake X -Xvfb :200 & +Xvfb :201 & XPID=$! # wait till it is up, run rofi with error message -sleep 1 && ./rofi -rnow -display :200 & +sleep 1 && ./rofi -rnow -display :201 & RPID=$! # send enter. sleep 5; -DISPLAY=:200 xdotool key 'shift+slash' +DISPLAY=:201 xdotool key 'shift+slash' sleep 0.4 -DISPLAY=:200 xdotool key 'shift+slash' +DISPLAY=:201 xdotool key 'shift+slash' sleep 0.4 -DISPLAY=:200 xdotool key 'shift+slash' +DISPLAY=:201 xdotool key 'shift+slash' sleep 0.4 -DISPLAY=:200 xdotool key Escape +DISPLAY=:201 xdotool key Escape # Get result, kill xvfb wait ${RPID} RETV=$? kill ${XPID} + +sleep 1 + exit ${RETV}