From 981b9c69d173b1e746efd0233792eeada8556ed4 Mon Sep 17 00:00:00 2001 From: Kornel Benko Date: Fri, 28 Dec 2012 16:22:25 +0100 Subject: [PATCH] 1.) Add format to CJK.lyx.lyx(missed in previous commit) 2.) Add lyx2lyx test to runtests.py. This is done with extra parameter only, and does not change the behaviour without this parameter. --- src/tex2lyx/test/CJK.lyx.lyx | 2 +- src/tex2lyx/test/CMakeLists.txt | 7 ++++ src/tex2lyx/test/runtests.py | 73 ++++++++++++++++++++++----------- 3 files changed, 57 insertions(+), 25 deletions(-) diff --git a/src/tex2lyx/test/CJK.lyx.lyx b/src/tex2lyx/test/CJK.lyx.lyx index ef1b7fbad3..6ebad1a19a 100644 --- a/src/tex2lyx/test/CJK.lyx.lyx +++ b/src/tex2lyx/test/CJK.lyx.lyx @@ -1,5 +1,5 @@ #LyX file created by tex2lyx 2.1.0dev -\lyxformat 453 +\lyxformat 456 \begin_document \begin_header \textclass article diff --git a/src/tex2lyx/test/CMakeLists.txt b/src/tex2lyx/test/CMakeLists.txt index 4994641a1c..36be360678 100644 --- a/src/tex2lyx/test/CMakeLists.txt +++ b/src/tex2lyx/test/CMakeLists.txt @@ -23,6 +23,13 @@ foreach(_fl ${_tex_tests}) "${TOP_SRC_DIR}/lib/scripts" "${CMAKE_CURRENT_BINARY_DIR}" ${fl}) + add_test(NAME tex2lyx2lyx/roundtrip/${_fl} + WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" + COMMAND ${LYX_PYTHON_EXECUTABLE} "${TOP_SRC_DIR}/src/tex2lyx/test/runtests.py" "uselyx2lyx" + "$" + "${TOP_SRC_DIR}/lib/scripts" + "${CMAKE_CURRENT_BINARY_DIR}" + ${fl}) endforeach() add_dependencies(lyx_run_tests ${_tex2lyx} ${_lyx}) diff --git a/src/tex2lyx/test/runtests.py b/src/tex2lyx/test/runtests.py index 406a96e22e..bfa4c2a2e3 100755 --- a/src/tex2lyx/test/runtests.py +++ b/src/tex2lyx/test/runtests.py @@ -18,35 +18,41 @@ import os, string, sys, time, difflib, filecmp, subprocess, re def usage(prog_name): - return "Usage: %s [ [[