The branch, master, has been updated.

- Log -----------------------------------------------------------------

commit 40b0f3dfaeb6d381493cc6b5b880bcec712ca92b
Merge: 9481d41 364de0c
Author: Kornel Benko <kor...@lyx.org>
Date:   Sat Jan 5 10:10:19 2013 +0100

    Merge branch 'master' of git.lyx.org:lyx


commit 9481d4182e225012632cc36a7cbc77e4beaf3d0e
Author: Kornel Benko <kor...@lyx.org>
Date:   Sat Jan 5 10:07:37 2013 +0100

    autotests: Enable the suffixed lyx to run the test too.
    (Hard coded 'lyx' replaced with real lyx-exe-file-name)

diff --git a/development/autotests/CMakeLists.txt 
b/development/autotests/CMakeLists.txt
index 3901ffd..d611307 100644
--- a/development/autotests/CMakeLists.txt
+++ b/development/autotests/CMakeLists.txt
@@ -37,6 +37,7 @@ if(Q_WS_X11)
         -DPO_BUILD_DIR=${TOP_BINARY_DIR}/po
         -DKEYTEST_INFILE=${_tf}
         -DBINDIR=$<TARGET_FILE_DIR:${_lyx}>
+       -DLYX=${_lyx}
        -DWORKDIR=${CMAKE_CURRENT_BINARY_DIR}/${LYX_HOME}
         -DKEYTEST_OUTFILE=${_t}-out.txt
         -DPACKAGE=${PACKAGE}
diff --git a/development/autotests/keytest.py b/development/autotests/keytest.py
index 82f316c..f403fdc 100755
--- a/development/autotests/keytest.py
+++ b/development/autotests/keytest.py
@@ -258,9 +258,13 @@ PO_BUILD_DIR = os.environ.get('PO_BUILD_DIR')
 if not PO_BUILD_DIR is None:
   print "PO_BUILD_DIR = " + PO_BUILD_DIR + "\n"
 
+lyx = os.environ.get('LYX')
+if lyx is None:
+    lyx = "lyx"
+
 lyx_exe = os.environ.get('LYX_EXE')
 if lyx_exe is None:
-    lyx_exe = "lyx"
+    lyx_exe = lyx
 
 xvkbd_exe = os.environ.get('XVKBD_EXE')
 if xvkbd_exe is None:
@@ -326,12 +330,12 @@ while not failed:
         print "Ignoring comment line: " + c
     elif c[0:9] == 'TestBegin':
         print "\n"
-        lyx_pid=os.popen("pidof lyx").read()
+        lyx_pid=os.popen("pidof " + lyx).read()
         if lyx_pid != "":
             print "Found running instance(s) of LyX: " + lyx_pid + ": killing 
them all\n"
-            intr_system("killall lyx", True)
+            intr_system("killall " + lyx, True)
             time.sleep(0.5)
-            intr_system("killall -KILL lyx", True)
+            intr_system("killall -KILL " + lyx, True)
         time.sleep(0.2)
         print "Starting LyX . . ."
         if lyx_userdir is None:
@@ -339,7 +343,7 @@ while not failed:
         else:
             intr_system(lyx_exe + " -userdir " + lyx_userdir + " " + c[9:] + 
"&")
         while True:
-            lyx_pid=os.popen("pidof lyx").read().rstrip()
+            lyx_pid=os.popen("pidof " + lyx).read().rstrip()
             if lyx_pid != "":
                 lyx_window_name=os.popen("wmctrl -l -p | grep ' " + 
str(lyx_pid) +  " ' | cut -d ' ' -f 1").read().rstrip()
                 if lyx_window_name != "":
diff --git a/development/autotests/single-test.cmake 
b/development/autotests/single-test.cmake
index 15b96ea..d09bc5a 100755
--- a/development/autotests/single-test.cmake
+++ b/development/autotests/single-test.cmake
@@ -15,6 +15,7 @@
 #       -DKEYTEST_INFILE=xxxx \
 #       -DKEYTEST_OUTFILE=xxx \
 #       -DBINDIR=xxx \
+#       -DLYX=xxx \
 #       -DWORKDIR=xxx \
 #       -DLOCALE_DIR=xxx \
 #       -DPO_BUILD_DIR=xxx \
@@ -23,7 +24,7 @@
 
 set(KEYTEST "${AUTOTEST_ROOT}/keytest.py")
 
-execute_process(COMMAND pidof lyx OUTPUT_VARIABLE LYX_PID RESULT_VARIABLE 
pidstat OUTPUT_VARIABLE pidres)
+execute_process(COMMAND pidof ${LYX} OUTPUT_VARIABLE LYX_PID RESULT_VARIABLE 
pidstat OUTPUT_VARIABLE pidres)
 message(STATUS "pidres = ${pidres}")
 if (NOT pidstat)
   # lyx already running, remove trailing '\n' from pid
@@ -44,7 +45,7 @@ else()
   set(LYX_WINDOW_NAME "")
 endif()
 
-set(LYX_EXE "${BINDIR}/lyx")
+set(LYX_EXE "${BINDIR}/${LYX}")
 set(XVKBD_EXE "${BINDIR}/xvkbd")
 
 # Environments needed by keytest.py
@@ -55,6 +56,7 @@ set(ENV{LYX_USERDIR} ${WORKDIR})
 set(ENV{LYX_PID} ${pidres})
 set(ENV{LYX_WINDOW_NAME} ${LYX_WINDOW_NAME})
 set(ENV{LYX_EXE} ${LYX_EXE})
+set(ENV{LYX} ${LYX})
 set(ENV{XVKBD_EXE} ${XVKBD_EXE})
 set(ENV{KEYTEST_INFILE} "${AUTOTEST_ROOT}/${KEYTEST_INFILE}")
 set(ENV{KEYTEST_OUTFILE} "${WORKDIR}/${KEYTEST_OUTFILE}")

-----------------------------------------------------------------------

Summary of changes:
 development/autotests/CMakeLists.txt    |    1 +
 development/autotests/keytest.py        |   14 +++++++++-----
 development/autotests/single-test.cmake |    6 ++++--
 3 files changed, 14 insertions(+), 7 deletions(-)


hooks/post-receive
-- 
The LyX Source Repository

Reply via email to