]> git.lyx.org Git - features.git/commitdiff
Cmake export tests: More tests to be inverted, suspended or made non-standard
authorKornel Benko <kornel@lyx.org>
Tue, 17 Nov 2015 17:22:45 +0000 (18:22 +0100)
committerKornel Benko <kornel@lyx.org>
Tue, 17 Nov 2015 17:22:45 +0000 (18:22 +0100)
All comments in revertedTests comes from Günter Milde
Non standard test is new. It should collect all tests
which may not work because of some missing non-standard
tex package or some exotic system font.

development/autotests/ExportTests.cmake
development/autotests/ignoredTests
development/autotests/lyxStatus.pm
development/autotests/nonstandardTests [new file with mode: 0644]
development/autotests/revertedTests
development/autotests/suspendedTests

index c3367a36cbed7ee67771b2fc2414955fbdaac00a..5b8f5cf17bf818a9cc8b307be6c312b7c0251edb 100644 (file)
@@ -75,32 +75,38 @@ macro(findexpr found testname listname)
   set(${found} ${_found})
 endmacro()
 
-macro(maketestname testname reverted listreverted listignored)
+macro(maketestname testname reverted listreverted listignored listnonstandard)
   string(REGEX MATCH "\\/[a-z][a-z](_[A-Z][A-Z])?\\/" _v ${${testname}})
   if(_v)
     string(REGEX REPLACE "\\/" "" _v ${_v})
     set(listrevertedx ${listreverted}_${_v})
-    #message(STATUS "${listreverted} ==> ${listrevertedx}")
     set(listignoredx ${listignored}_${_v})
-    #message(STATUS "${listignored} ==> ${listignoredx}")
+    set(listnonstandardx ${listnonstandard}_${_v})
   else()
     set(listrevertedx ${listreverted})
     set(listignoredx ${listignored})
+    set(listnonstandardx ${listnonstandard})
   endif()
   findexpr(mfound ${testname} ${listignoredx})
   if (NOT mfound)
-    # check if test _may_ be in listreverted
-    string(REGEX MATCH "_(systemF|texF|pdf3|pdf2|pdf|dvi)$" _v ${${testname}})
-    if (_v)
-      findexpr(mfound ${testname} ${listrevertedx})
-    else()
-      set(mfound OFF)
-    endif()
-    if (NOT mfound)
-      set(${reverted} 0)
-    else()
-      set(${reverted} 1)
-      set(${testname} "INVERTED_SEE-README.ctest_${${testname}}")
+    # check if they are non-standard
+    findexpr(nsfound ${testname} ${listnonstandardx})
+    if (nsfound)
+      set(${testname} "NON_STANDARD.${${testname}}")
+    else ()
+      string(REGEX MATCH "_(systemF|texF|pdf3|pdf2|pdf|dvi)$" _v ${${testname}})
+      # check if test _may_ be in listreverted
+      if (_v)
+        findexpr(mfound ${testname} ${listrevertedx})
+      else()
+        set(mfound OFF)
+      endif()
+      if (NOT mfound)
+        set(${reverted} 0)
+      else()
+        set(${reverted} 1)
+        set(${testname} "INVERTED_SEE-README.ctest_${${testname}}")
+      endif()
     endif()
   else()
     set(${testname} "")
@@ -138,10 +144,12 @@ endmacro()
 loadTestList(revertedTests revertedTests)
 loadTestList(ignoredTests ignoredTests)
 loadTestList(suspendedTests suspendedTests)
+loadTestList(nonstandardTests nonstandardTests)
 
 macro(handlesuspended TestName reverted testlabel)
   set(mylabel ${testlabel})
   set(myreverted ${reverted})
+
   if (${reverted})
     # check suspension only for reverted tests
     findexpr(tfound TestName suspendedTests)
@@ -149,6 +157,11 @@ macro(handlesuspended TestName reverted testlabel)
       set(mylabel "suspended")
       set(myreverted 0) # if test is to be suspended, remove the 'reverted' flag
     endif()
+  else ()
+    # check for nonstandard
+    if ("${TestName}" MATCHES "^NON_STANDARD")
+      set(mylabel "nonstandard")
+    endif()
   endif()
   setmarkedtestlabel(${TestName} ${myreverted} ${mylabel})
 endmacro()
@@ -175,7 +188,7 @@ foreach(libsubfolderx lib/doc lib/examples lib/templates)
     # Strip extension
     string(REGEX REPLACE "\\.lyx$" "" f ${f})
     set(TestName "export/${libsubfolder}/${f}_lyx16")
-    maketestname(TestName reverted revertedTests ignoredTests)
+    maketestname(TestName reverted revertedTests ignoredTests nonstandardTests)
     if(TestName)
       add_test(NAME ${TestName}
         WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${LYX_HOME}"
@@ -196,7 +209,7 @@ foreach(libsubfolderx lib/doc lib/examples lib/templates)
     if(LYX_PYTHON_EXECUTABLE)
       # For use of lyx2lyx we need the python executable
       set(TestName "lyx2lyx/${libsubfolder}/${f}")
-      maketestname(TestName reverted revertedTests ignoredTests)
+      maketestname(TestName reverted revertedTests ignoredTests nonstandardTests)
       if(TestName)
         add_test(NAME ${TestName}
           WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${LYX_HOME}"
@@ -210,7 +223,7 @@ foreach(libsubfolderx lib/doc lib/examples lib/templates)
       endif()
     endif()
     set(TestName "check_load/${libsubfolder}/${f}")
-    maketestname(TestName reverted revertedTests ignoredTests)
+    maketestname(TestName reverted revertedTests ignoredTests nonstandardTests)
     if(TestName)
       add_test(NAME ${TestName}
         WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${LYX_HOME}"
@@ -236,7 +249,7 @@ foreach(libsubfolderx lib/doc lib/examples lib/templates)
         else()
           set(TestName "export/${libsubfolder}/${f}_${format}_${fonttype}")
         endif()
-        maketestname(TestName reverted revertedTests ignoredTests)
+        maketestname(TestName reverted revertedTests ignoredTests nonstandardTests)
         if(TestName)
           add_test(NAME ${TestName}
             WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/${LYX_HOME}"
index 99695bc85385532a1543b1c4560cfccda73c6f75..5fc1a25506926c8cab605f01058cb935843516ec 100644 (file)
@@ -4,4 +4,5 @@
 # latex8.sty is obsolete and replaced by IEEEconf.
 check_load/templates/attic/latex8
 export/templates/attic/latex8_pdf.*
+exportt/.*/ko[/_].*_texF
 #
index cfdeceb0f6a49bb46d7b03d0e7b7ce7d96865c9e..f67451c5715e28d947962a8d4a2b2e634c6f1774 100644 (file)
@@ -247,8 +247,7 @@ sub checkForPreamble($)
     my $comments = newMatch("search" => '^([^%]*)([%]+)([^%]*)$',
                            "filetype" => "replace_only",
                            "result" => ["1", "2"]);
-    #setMatching([$rElem, $comments]);
-    setMatching([$rElem]);
+    setMatching([$rElem, $comments]);
     return(1);
   }
   return(0);
diff --git a/development/autotests/nonstandardTests b/development/autotests/nonstandardTests
new file mode 100644 (file)
index 0000000..6755a01
--- /dev/null
@@ -0,0 +1,5 @@
+# Tests using some non-standard tex class
+export/templates/IUCr-article_(dvi|pdf).*
+export/templates/es_beamer-conference-ornate-20min_pdf4_texF
+export/templates/kluwer_pdf5_systemF
+export/templates/kluwer_pdf[45]_systemF
index 5256992eef6718870e004f86b589aa1cd6688fd2..e8fa1882aa25ac8541f755f31295c097102f88f9 100644 (file)
@@ -134,3 +134,16 @@ export/doc/de/(Customization_pdf5|EmbeddedObjects_pdf4)_systemF
 # Seems to be a case of the polyglossia + language-nesting problem
 export/doc/es/Customization_pdf[45]_systemF
 export/doc/es/Additional_pdf4_texF
+#
+# Files in the attic with changed settings 
+# (i.e. could be ERT, package incompatiblity, ...)
+export/doc/attic/it_(Customization_pdf5|UserGuide_dvi3|UserGuide_pdf4)_systemF
+export/doc/attic/sk_UserGuide_pdf4_texF
+#
+# Don't know what is to be expected with indices and Xe/Lua
+export/doc/es/EmbeddedObjects_(dvi3|pdf[45])_texF
+#
+# Babel's Russian language definition file has the same
+# problem as LyX 2.0: it does not care for the combi Xe/Lua + TeX fonts: after
+# testing the engine, it switches to "unicode modus".
+export/examples/(ru|uk)/splash_(dvi3|pdf[45])_texF
\ No newline at end of file
index 3e6efaa0ba55ab6f8ca4f85f39cb17ac3101d556..6fa0914c351e2873bde1271ddefb2bc5df097839 100644 (file)
@@ -1 +1,2 @@
 INV.*(dvi3|pdf4|pdf5)_texF
+INV.*/attic/.*F