[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: * tp/t/test_sort.t: setup a configuration with Te
From: |
Patrice Dumas |
Subject: |
branch master updated: * tp/t/test_sort.t: setup a configuration with Texinfo::MainConfig instead of using the parser. |
Date: |
Mon, 06 Sep 2021 05:17:51 -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 9dfb050 * tp/t/test_sort.t: setup a configuration with
Texinfo::MainConfig instead of using the parser.
9dfb050 is described below
commit 9dfb050d5e80cea8cfcbecda413de10ca0c57151
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Mon Sep 6 11:16:51 2021 +0200
* tp/t/test_sort.t: setup a configuration with Texinfo::MainConfig
instead of using the parser.
---
tp/t/test_sort.t | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/tp/t/test_sort.t b/tp/t/test_sort.t
index dd65388..08cb95f 100644
--- a/tp/t/test_sort.t
+++ b/tp/t/test_sort.t
@@ -10,6 +10,8 @@ use Texinfo::Convert::Text;
use Texinfo::Parser;
use Texinfo::Structuring;
use Test::Deep;
+# package Texinfo::MainConfig is in Texinfo::Config
+use Texinfo::Config;
ok(1, "modules loading");
@@ -44,12 +46,10 @@ my $registrar = $parser->registered_errors();
my ($index_names, $merged_indices) = $parser->indices_information();
my $index_entries = Texinfo::Structuring::merge_indices($index_names);
my $parser_informations = $parser->global_informations();
-# FIXME this is wrong, there should be an object
-# holding only configuration that is not a parser
-$parser->{'OUTPUT_ENCODING_NAME'} =
$parser_informations->{'input_encoding_name'};
-$parser->{'ENABLE_ENCODING'} = 1;
+my $main_configuration = Texinfo::MainConfig::new({'ENABLE_ENCODING' => 1});
+Texinfo::Common::set_output_encodings($main_configuration,
$parser_informations);
my ($sorted_index_entries, $index_entries_sort_strings)
- = Texinfo::Structuring::sort_indices($parser, $registrar, $parser,
+ = Texinfo::Structuring::sort_indices($parser, $registrar,
$main_configuration,
$index_entries);
my @entries = ();
@@ -65,7 +65,7 @@ my @entries_ref = ('!', '"', 'aaaaaaaaaaaa', 'e', 'E', 'ł',
'ẽ');
cmp_deeply (\@entries, \@entries_ref, 'sorted index entries');
my ($sorted_index_entries_by_letter, $by_letter_index_entries_sort_strings)
- = Texinfo::Structuring::sort_indices($parser, $parser, $parser,
+ = Texinfo::Structuring::sort_indices($parser, $registrar,
$main_configuration,
$index_entries, 'by_letter');
my @letter_entries_ref = (
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: * tp/t/test_sort.t: setup a configuration with Texinfo::MainConfig instead of using the parser.,
Patrice Dumas <=
- Prev by Date:
branch master updated: * tp/Texinfo/Convert/Text.pm (copy_options_for_convert_text), tp/Texinfo/Common.pm, tp/Texinfo/Convert/DocBook.pm, tp/Texinfo/Convert/HTML.pm, tp/Texinfo/Convert/IXIN.pm, tp/Texinfo/Convert/Info.pm, tp/Texinfo/Convert/LaTeX.pm, tp/Texinfo/Convert/Plaintext.pm, tp/Texinfo/Convert/TexinfoXML.pm, tp/Texinfo/Convert/Text.pm, tp/Texinfo/Convert/TextContent.pm, tp/Texinfo/Structuring.pm, tp/init/chm.pm, tp/init/highlight_syntax.pm: move copy_options_for_convert_text() from Texinfo::Common to Tex [...]
- Next by Date:
branch master updated: * tp/Texinfo/Convert/Converter.pm (set_global_document_commands), tp/Texinfo/Convert/HTML.pm (_prepare_elements), tp/Texinfo/Convert/IXIN.pm, tp/Texinfo/Convert/Info.pm, tp/Texinfo/Convert/TexinfoXML.pm: rename _set_global_multiple_commands() as set_global_document_commands(). Add a list of global commands to process in argument. In Texinfo::Convert::HTML, use set_global_document_commands() in more specific ways specifying the changed variables and restoring after use if not needed anymor [...]
- Previous by thread:
branch master updated: * tp/Texinfo/Convert/Text.pm (copy_options_for_convert_text), tp/Texinfo/Common.pm, tp/Texinfo/Convert/DocBook.pm, tp/Texinfo/Convert/HTML.pm, tp/Texinfo/Convert/IXIN.pm, tp/Texinfo/Convert/Info.pm, tp/Texinfo/Convert/LaTeX.pm, tp/Texinfo/Convert/Plaintext.pm, tp/Texinfo/Convert/TexinfoXML.pm, tp/Texinfo/Convert/Text.pm, tp/Texinfo/Convert/TextContent.pm, tp/Texinfo/Structuring.pm, tp/init/chm.pm, tp/init/highlight_syntax.pm: move copy_options_for_convert_text() from Texinfo::Common to Tex [...]
- Next by thread:
branch master updated: * tp/Texinfo/Convert/Converter.pm (set_global_document_commands), tp/Texinfo/Convert/HTML.pm (_prepare_elements), tp/Texinfo/Convert/IXIN.pm, tp/Texinfo/Convert/Info.pm, tp/Texinfo/Convert/TexinfoXML.pm: rename _set_global_multiple_commands() as set_global_document_commands(). Add a list of global commands to process in argument. In Texinfo::Convert::HTML, use set_global_document_commands() in more specific ways specifying the changed variables and restoring after use if not needed anymor [...]
- Index(es):