Compare commits

...

4 Commits

Author SHA1 Message Date
Jean-Marc Lasgouttes
77e4092b99 Move assertion at the right position
It would wrongly trigger when doing a multi-cell selection.
2024-09-19 23:18:47 +02:00
Scott Kostyshak
92c7c33d9e ctests: invert lyx2lyx tests that fail TeX export
These fail when exporting to TeX, but since they have to do with old
formats, it's not clear it's worth the time to investigate.

These started failing once we check the exit code of LyX's TeX
export (at c7be9780).
2024-09-19 22:38:49 +02:00
Scott Kostyshak
c7be978098 ctests: exit with error if export to .tex fails
Now that we detect and export to the correct TeX format (instead of
assuming pdflatex), we can make the check more strict by giving an
error if LyX exits with error from the export.
2024-09-19 22:34:37 +02:00
Scott Kostyshak
03f0392849 ctests: default for Japanese + systemF is pdf4
This fixes the following tests:

  export/examples/ja/Modules/Rnw_%28knitr%29_lyx22
  export/examples/ja/Modules/Rnw_%28knitr%29_lyx23
  export/examples/ja/Modules/Sweave_lyx22
  export/examples/ja/Modules/Sweave_lyx23
2024-09-19 22:01:38 +02:00
4 changed files with 11 additions and 2 deletions

View File

@ -283,6 +283,11 @@ if (extension MATCHES "\\.lyx$")
COMMAND ${lyx} -userdir "${LYX_TESTS_USERDIR}" -E ${_texformat} ${used_tex_file} "${LYX_SOURCE}"
RESULT_VARIABLE _errx)
endif()
if(_errx)
set(_err -1)
Summary(_err "Exporting ${LYX_SOURCE} to format ${_texformat} failed")
break()
endif()
endif()
endif()
get_md5sum(result_file_name result_md5sum _err)

View File

@ -53,6 +53,10 @@ export/export/lyx2lyx/lyx_2_3_test_lyx(16|20|21|22)
# Additional empty lines (vs. Separator latexpar) with every round-trip
# before an ERT nested in a Description list:
export/export/lyx2lyx/lyx_2_3_test2_lyx(16|20)
# Gives error when exporting to TeX. These are old formats, so it is not
# clear it is worth the time to try to fix the issue.
export/doc/ja/UserGuide_lyx(16|20)
export/examples/ja/Modules/LilyPond_Book_lyx(16|20)
# nonstandard tests failing for unknown reason:
export/templates/Articles/R_Journal_(dvi3|pdf[45])_systemF

View File

@ -30,7 +30,7 @@ if (defined($useNonTexFonts) && defined($outputFormat)) {
if ($useNonTexFonts) {
if ($outputFormat eq "default") {
if ($language eq "japanese") {
$outputFormat = "pdf3";
$outputFormat = "pdf4";
}
else {
$outputFormat = "pdf5";

View File

@ -72,8 +72,8 @@ void Statistics::update(Text const & text)
void Statistics::update(CursorSlice const & from, CursorSlice & to)
{
LASSERT(from.text() == to.text(), return);
if (from.idx() == to.idx()) {
LASSERT(from.text() == to.text(), return);
if (from.pit() == to.pit()) {
update(from.paragraph(), from.pos(), to.pos());
} else {