3 # This script invokes the keytest.py script with the simple set-up needed
4 # to re-run deterministic regression tests that one would like to have.
6 # Usage: run-test.sh <test-in.txt>
8 # See the hello-world-in.txt for an example syntax and description
10 KEYTEST=${KEYTEST:-./keytest.py}
12 export KEYTEST_OUTFILE=out.txt
13 export KEYTEST_INFILE=in-sample.txt
14 if [ "$1" != "" ]; then
18 BASE=$( echo $KEYTEST_INFILE | sed 's/-in\.\(txt\|sh\)$//')
19 if [ -e $BASE.lyx.emergency ]; then
20 echo "removing $BASE.lyx.emergency"
21 rm $BASE.lyx.emergency
25 if [ "$(pidof lyx)" != "" ]; then
26 export LYX_PID=$(pidof lyx)
27 export LYX_WINDOW_NAME=$(wmctrl -l -p | grep " $LYX_PID " | cut -d ' ' -f 1);
31 echo LYX_WINDOW_NAME=$LYX_WINDOW_NAME
34 export LYX_EXE=${LYX_EXE:-../../src/lyx}
36 if [ "$XVKBD_HACKED" != "" ]; then
37 export XVKBD_EXE=${XVKBD_EXE:-./xvkbd/xvkbd};
39 export XVKBD_EXE=${XVKBD_EXE:-xvkbd};
42 python -m trace --trace $KEYTEST