texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: * tp/t/*.t, tp/t/test_utils.pl (test): move ENABL


From: Patrice Dumas
Subject: branch master updated: * tp/t/*.t, tp/t/test_utils.pl (test): move ENABLE_ENCODING setup in tests to the converter options, as it is not used in structuring anymore.
Date: Thu, 04 Apr 2024 13:51:13 -0400

This is an automated email from the git hooks/post-receive script.

pertusus pushed a commit to branch master
in repository texinfo.

The following commit(s) were added to refs/heads/master by this push:
     new f6c9581c45 * tp/t/*.t, tp/t/test_utils.pl (test): move ENABLE_ENCODING 
setup in tests to the converter options, as it is not used in structuring 
anymore.
f6c9581c45 is described below

commit f6c9581c458185abce3fa7a7a6b793ad5683bfb9
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Thu Apr 4 19:50:57 2024 +0200

    * tp/t/*.t, tp/t/test_utils.pl (test): move ENABLE_ENCODING setup in
    tests to the converter options, as it is not used in structuring
    anymore.
---
 ChangeLog                |  6 ++++++
 tp/Texinfo/Indices.pm    |  1 +
 tp/t/09indices.t         | 21 ++++++++++++---------
 tp/t/formats_encodings.t |  6 +++---
 tp/t/html_tests.t        | 36 ++++++++++++++++++------------------
 tp/t/latex_tests.t       |  2 +-
 tp/t/plaintext_tests.t   | 12 ++++++------
 tp/t/test_utils.pl       | 18 +++---------------
 8 files changed, 50 insertions(+), 52 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 3753654fcc..36fdf5af4b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2024-04-04  Patrice Dumas  <pertusus@free.fr>
+
+       * tp/t/*.t, tp/t/test_utils.pl (test): move ENABLE_ENCODING setup in
+       tests to the converter options, as it is not used in structuring
+       anymore.
+
 2024-04-03  Patrice Dumas  <pertusus@free.fr>
 
        Rename BODYTEXT customization variable as BODY_ELEMENT_ATTRIBUTES
diff --git a/tp/Texinfo/Indices.pm b/tp/Texinfo/Indices.pm
index 94a3380863..dc3004fd81 100644
--- a/tp/Texinfo/Indices.pm
+++ b/tp/Texinfo/Indices.pm
@@ -138,6 +138,7 @@ sub _sort_index_entries($$)
   return $res;
 }
 
+# Only called from converters
 sub setup_index_entry_keys_formatting($)
 {
   my $customization_information = shift;
diff --git a/tp/t/09indices.t b/tp/t/09indices.t
index f98652cdeb..0dad7edc6e 100644
--- a/tp/t/09indices.t
+++ b/tp/t/09indices.t
@@ -1053,23 +1053,25 @@ my @file_encodings_tests = (
 @documentencoding us-ascii
 '.$encoding_index_text,
 {'skip' => ($] < 5.018) ? 'Perl too old incompatible Unicode collation' : 
undef,
-'ENABLE_ENCODING' => 0, 'full_document' => 1}
+'full_document' => 1},
+{'ENABLE_ENCODING' => 0}
 ],
 ['encoding_index_latin1',
 undef,
 {'skip' => ($] < 5.018) ? 'Perl too old incompatible Unicode collation' : 
undef,
-'test_file' => 'encoding_index_latin1.texi', 'ENABLE_ENCODING' => 0},
+'test_file' => 'encoding_index_latin1.texi'},
+{'ENABLE_ENCODING' => 0}
 ],
 ['encoding_index_utf8',
 undef,
 {'skip' => ($] < 5.018) ? 'Perl too old incompatible Unicode collation' : 
undef,
-'test_file' => 'encoding_index_utf8.texi', 'ENABLE_ENCODING' => 0},
+'test_file' => 'encoding_index_utf8.texi',},
+{'ENABLE_ENCODING' => 0},
 ],
 ['encoding_index_utf8_no_use_unicode',
 undef,
-{'test_file' => 'encoding_index_utf8.texi', 'ENABLE_ENCODING' => 0,
-'USE_UNICODE_COLLATION' => 0},
-{'USE_UNICODE_COLLATION' => 0},
+{'test_file' => 'encoding_index_utf8.texi', 'USE_UNICODE_COLLATION' => 0},
+{'ENABLE_ENCODING' => 0, 'USE_UNICODE_COLLATION' => 0},
 ],
 ['encoding_index_ascii_enable_encoding',
 '
@@ -1077,18 +1079,19 @@ undef,
 @documentencoding us-ascii
 '.$encoding_index_text,
 {'skip' => ($] < 5.018) ? 'Perl too old incompatible Unicode collation' : 
undef,
-'ENABLE_ENCODING' => 1, 'full_document' => 1},
+'full_document' => 1},
+{'ENABLE_ENCODING' => 1,}
 ],
 ['encoding_index_latin1_enable_encoding',
 undef,
 {'skip' => ($] < 5.018) ? 'Perl too old incompatible Unicode collation' : 
undef,
-'test_file' => 'encoding_index_latin1.texi', 'ENABLE_ENCODING' => 1},
+'test_file' => 'encoding_index_latin1.texi',},
 {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}
 ],
 ['encoding_index_utf8_enable_encoding',
 undef,
 {'skip' => ($] < 5.018) ? 'Perl too old incompatible Unicode collation' : 
undef,
-'test_file' => 'encoding_index_utf8.texi', 'ENABLE_ENCODING' => 1},
+'test_file' => 'encoding_index_utf8.texi',},
 {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}
 ],
 );
diff --git a/tp/t/formats_encodings.t b/tp/t/formats_encodings.t
index 38a9769e2b..45ac11a3fb 100644
--- a/tp/t/formats_encodings.t
+++ b/tp/t/formats_encodings.t
@@ -318,13 +318,13 @@ $latin1_accents_text
 $weird_accents_text
 ],
 ['weird_accents_disable_encoding',
-$weird_accents_text, {'ENABLE_ENCODING' => 0}
+$weird_accents_text, {}, {'ENABLE_ENCODING' => 0}
 ],
 ['accent',
 $accents_text
 ],
 ['accent_enable_encoding',
-$accents_text, {'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 1}
+$accents_text, {}, {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}
 ],
 ['accent_argument_non_ascii',
 '@node Top
@@ -361,7 +361,7 @@ $at_commands_in_refs_text,
 
 my @html_text_cases = (
 ['accentenc_enable_encoding',
-$latin1_accents_text, {'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 1}
+$latin1_accents_text, {}, {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}
 ],
 );
 
diff --git a/tp/t/html_tests.t b/tp/t/html_tests.t
index ce67f7c359..ad3e04cb97 100644
--- a/tp/t/html_tests.t
+++ b/tp/t/html_tests.t
@@ -841,12 +841,12 @@ AA @^e --- -- \'` \'\' ``'],
 ['utf8_enable_encoding',
 '@documentencoding utf-8
 
-AA @^e --- -- \'` \'\' ``', {'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 
1}],
+AA @^e --- -- \'` \'\' ``', {}, {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' 
=> 1}],
 ['utf8_enable_encoding_no_use_iso',
 '@documentencoding utf-8
 
-AA @^e --- -- \'` \'\' ``', {'ENABLE_ENCODING' => 1},
-                            {'OUTPUT_CHARACTERS' => 1, 'USE_ISO' => 0}],
+AA @^e --- -- \'` \'\' ``', {}, {'ENABLE_ENCODING' => 1,
+                            'OUTPUT_CHARACTERS' => 1, 'USE_ISO' => 0}],
 ['utf8_use_numeric_entity',
 '@documentencoding utf-8
 
@@ -854,8 +854,8 @@ AA @^e --- -- \'` \'\' ``', {}, {'USE_NUMERIC_ENTITY' => 
1}],
 ['utf8_enable_encoding_use_numeric_entity',
 '@documentencoding utf-8
 
-AA @^e --- -- \'` \'\' ``', {'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 
1,
-                                                       'USE_NUMERIC_ENTITY' => 
1}],
+AA @^e --- -- \'` \'\' ``', {}, {'ENABLE_ENCODING' => 1,
+                    'OUTPUT_CHARACTERS' => 1, 'USE_NUMERIC_ENTITY' => 1}],
 ['ref_in_preformatted',
 '@node Top
 
@@ -935,18 +935,18 @@ my @test_cases_file_text = (
 ['test_accents_sc_default',
 undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi'}],
 ['test_accents_sc_enable_encoding',
-undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi',
-        'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 1}],
+undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi',},
+       {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}],
 ['test_accents_sc_default_latin1',
 undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi'}],
 ['test_accents_sc_enable_encoding_latin1',
-undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi',
-        'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 1}],
+undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi',},
+       {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}],
 ['test_accents_sc_default_usascii',
 undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi'}],
 ['test_accents_sc_enable_encoding_usascii',
-undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi',
-        'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 1}],
+undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi',},
+        {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}],
 ['test_accents_sc_use_numeric_entity',
 undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi'},
        {'USE_NUMERIC_ENTITY' => 1}],
@@ -955,13 +955,13 @@ undef, {'test_file' => 
'punctuation_small_case_accents_utf8.texi'},
 undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi'},
         {'OUTPUT_ENCODING_NAME' => 'utf-8'}],
 ['test_accents_sc_enable_encoding_to_utf8_latin1',
-undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi',
-         'ENABLE_ENCODING' => 1},
-        {'OUTPUT_CHARACTERS' => 1, 'OUTPUT_ENCODING_NAME' => 'utf-8'}],
+undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi',},
+       {'ENABLE_ENCODING' => 1,
+       'OUTPUT_CHARACTERS' => 1, 'OUTPUT_ENCODING_NAME' => 'utf-8'}],
 ['test_accents_sc_enable_encoding_to_utf8_usascii',
-undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi',
-         'ENABLE_ENCODING' => 1},
-        {'OUTPUT_CHARACTERS' => 1, 'OUTPUT_ENCODING_NAME' => 'utf-8'}],
+undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi',},
+        {'ENABLE_ENCODING' => 1,
+         'OUTPUT_CHARACTERS' => 1, 'OUTPUT_ENCODING_NAME' => 'utf-8'}],
 );
 
 my $css_init_file_texinfo = '@node Top
@@ -1212,7 +1212,7 @@ $itemize_arguments_text
 ],
 ['itemize_arguments_enable_encoding',
 $itemize_arguments_text
-, {'ENABLE_ENCODING' => 1}, {'OUTPUT_CHARACTERS' => 1}
+, {}, {'ENABLE_ENCODING' => 1, 'OUTPUT_CHARACTERS' => 1}
 ],
 ['itemize_tieaccent',
 '@itemize @tieaccent{ab}
diff --git a/tp/t/latex_tests.t b/tp/t/latex_tests.t
index 7c01e72970..f641261b41 100644
--- a/tp/t/latex_tests.t
+++ b/tp/t/latex_tests.t
@@ -757,7 +757,7 @@ b!}
 $indices_text
 ],
 ['indices_disable_encoding',
-$indices_text, {ENABLE_ENCODING => 0,}, {ENABLE_ENCODING => 0,}
+$indices_text, {}, {ENABLE_ENCODING => 0,}
 ],
 ['error_in_sectioning_command',
 '@contents
diff --git a/tp/t/plaintext_tests.t b/tp/t/plaintext_tests.t
index ceba400026..f9bf2d6674 100644
--- a/tp/t/plaintext_tests.t
+++ b/tp/t/plaintext_tests.t
@@ -1032,24 +1032,24 @@ undef, {'test_file' => 'nodequote.texi',},
 ['punctuation_sc_accents_default',
 undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi'}],
 ['punctuation_sc_accents_disable_encoding',
-undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi',
-        'ENABLE_ENCODING' => 0}],
+undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi',},
+       {'ENABLE_ENCODING' => 0}],
 ['punctuation_sc_accents_ascii_glyph',
 undef, {'test_file' => 'punctuation_small_case_accents_utf8.texi'},
         {'ASCII_GLYPH' => 1}],
 ['punctuation_sc_accents_default_latin1',
 undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi'}],
 ['punctuation_sc_accents_disable_encoding_latin1',
-undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi',
-        'ENABLE_ENCODING' => 0}],
+undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi',},
+       {'ENABLE_ENCODING' => 0}],
 ['punctuation_sc_accents_ascii_glyph_latin1',
 undef, {'test_file' => 'punctuation_small_case_accents_latin1.texi'},
         {'ASCII_GLYPH' => 1}],
 ['punctuation_sc_accents_default_usascii',
 undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi'}],
 ['punctuation_sc_accents_disable_encoding_usascii',
-undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi',
-        'ENABLE_ENCODING' => 0}],
+undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi',},
+       {'ENABLE_ENCODING' => 0}],
 ['punctuation_sc_accents_ascii_glyph_usascii',
 undef, {'test_file' => 'punctuation_small_case_accents_us_ascii.texi'},
         {'ASCII_GLYPH' => 1}],
diff --git a/tp/t/test_utils.pl b/tp/t/test_utils.pl
index de26a822e0..035da2be3f 100644
--- a/tp/t/test_utils.pl
+++ b/tp/t/test_utils.pl
@@ -922,18 +922,6 @@ sub test($$)
   my $added_main_configurations = {'FORMAT_MENU' => 'menu',
                                    'CHECK_MISSING_MENU_ENTRY' => 1};
 
-  # FIXME this has changed
-  # this is only used for index keys sorting in structuring
-  foreach my $structuring_and_converter_option ('ENABLE_ENCODING') {
-    if (defined($parser_options->{$structuring_and_converter_option})) {
-      $added_main_configurations->{$structuring_and_converter_option}
-        = $parser_options->{$structuring_and_converter_option};
-      $converter_options->{$structuring_and_converter_option}
-        = $parser_options->{$structuring_and_converter_option};
-      delete $parser_options->{$structuring_and_converter_option};
-    }
-  }
-
   foreach my $structuring_option ('CHECK_NORMAL_MENU_STRUCTURE',
                                   'FORMAT_MENU', 'USE_UNICODE_COLLATION',
                                   'COLLATION_LANGUAGE') {
@@ -982,7 +970,7 @@ sub test($$)
   my $init_files_options = {};
   my $init_file_directories = [$srcdir.'init/', $srcdir.'t/init/'];
   # the init file names are supposed to be binary strings.  Since they
-  # are not encoded anywhere, probably only non ascii file names should
+  # are not encoded anywhere, probably only ascii file names should
   # be used.
   # FIXME what if srcdir is non ascii (srcdir is truly a binary string).
   if ($parser_options and $parser_options->{'init_files'}) {
@@ -1068,7 +1056,7 @@ sub test($$)
     $main_configuration->set_conf('novalidate', 1);
   }
 
-  # Now that all the configuration has been set, associate it to the
+  # Now that all the configuration has been set, associate it with the
   # document XS
   $main_configuration->register_XS_document_main_configuration($document);
 
@@ -1146,7 +1134,7 @@ sub test($$)
   $tree = $document->tree();
 
   my $indices_information = $document->indices_information();
-  # FIXME maybe it would be good to compare $merged_index_entries?
+  # TODO maybe it would be good to compare $merged_index_entries?
   my $merged_index_entries = $document->merged_indices();
 
   # only print indices information if it differs from the default



reply via email to

[Prev in Thread] Current Thread [Next in Thread]