From ade91a38756174e372405620794fefaebbc47a47 Mon Sep 17 00:00:00 2001 From: Dave Davenport Date: Thu, 31 Dec 2015 23:14:38 +0100 Subject: [PATCH] Add simple drun test --- Makefile.am | 2 ++ test/run_drun_test.sh | 22 ++++++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100755 test/run_drun_test.sh diff --git a/Makefile.am b/Makefile.am index 758d6944..b7f0330a 100644 --- a/Makefile.am +++ b/Makefile.am @@ -192,6 +192,8 @@ test-x: ${bin_PROGRAMS} $(top_srcdir)/test/run_test.sh 211 $(top_srcdir)/test/run_daemon_test.sh $(top_builddir) echo "Test xr dump" $(top_srcdir)/test/run_test.sh 212 $(top_srcdir)/test/xr_dump_test.sh $(top_builddir) $(top_srcdir) + echo "Test drun" + $(top_srcdir)/test/run_test.sh 213 $(top_srcdir)/test/run_drun_test.sh $(top_builddir) echo "End tests" diff --git a/test/run_drun_test.sh b/test/run_drun_test.sh new file mode 100755 index 00000000..34559cb3 --- /dev/null +++ b/test/run_drun_test.sh @@ -0,0 +1,22 @@ +#!/usr/bin/env bash + +rofi -show drun -modi drun & +RPID=$! + +# send enter. +sleep 5; +xdotool key 't' +sleep 0.4 +xdotool key 'r' +sleep 0.4 +xdotool key 'u' +sleep 0.4 +xdotool key 'e' +sleep 0.4 +xdotool key Return + +# Get result, kill xvfb +wait ${RPID} +RETV=$? + +exit ${RETV}