texinfo-commits
[Top][All Lists]
Advanced

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

branch master updated: * tp/Makefile.tres, tp/t/60macro.t: add macro_bef


From: Patrice Dumas
Subject: branch master updated: * tp/Makefile.tres, tp/t/60macro.t: add macro_before_specific_line_command_args test.
Date: Sun, 05 Feb 2023 11:34:56 -0500

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 39d2238274 * tp/Makefile.tres, tp/t/60macro.t: add 
macro_before_specific_line_command_args test.
39d2238274 is described below

commit 39d22382748da57f641888df3c04323fab0b2c22
Author: Patrice Dumas <pertusus@free.fr>
AuthorDate: Sun Feb 5 17:34:42 2023 +0100

    * tp/Makefile.tres, tp/t/60macro.t: add
    macro_before_specific_line_command_args test.
---
 ChangeLog                                          |   5 +
 tp/Makefile.tres                                   |   1 +
 tp/TODO                                            |   7 -
 tp/t/60macro.t                                     |   7 +
 .../macro_before_specific_line_command_args.pl     | 206 +++++++++++++++++++++
 5 files changed, 219 insertions(+), 7 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 436e5f17e4..a9d82a7fc7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2023-02-05  Patrice Dumas  <pertusus@free.fr>
+
+       * tp/Makefile.tres, tp/t/60macro.t: add
+       macro_before_specific_line_command_args test.
+
 2023-02-05  Patrice Dumas  <pertusus@free.fr>
 
        * tp/Texinfo/XS/parsetexi/end_line.c (end_line_misc_line): remove the
diff --git a/tp/Makefile.tres b/tp/Makefile.tres
index e9873faba5..42a1986d19 100644
--- a/tp/Makefile.tres
+++ b/tp/Makefile.tres
@@ -1196,6 +1196,7 @@ test_files_generated_list = 
$(test_tap_files_generated_list) \
   t/results/macro/leading_spaces_no_ignore.pl \
   t/results/macro/line_after_recursive_call.pl \
   t/results/macro/macro_after_paragraph.pl \
+  t/results/macro/macro_before_specific_line_command_args.pl \
   t/results/macro/macro_expands_to_empty.pl \
   t/results/macro/macro_expansion.pl \
   t/results/macro/macro_for_dot_in_menu_not_separator.pl \
diff --git a/tp/TODO b/tp/TODO
index 73414e7422..7dd0fe27d5 100644
--- a/tp/TODO
+++ b/tp/TODO
@@ -17,13 +17,6 @@ or value expansion. aliases.
 done: source_marks structures, with beginning and end of included file, @
 protecting end of line in @def*, @setfilename in included files.
 
-check that there is a test of something like
-@macro cpfn
- cp fn
-@end macro
-
-@syncodeindex@cpfn{}
-
 Bugs
 ====
 
diff --git a/tp/t/60macro.t b/tp/t/60macro.t
index ef50703dc0..cfd0fecae6 100644
--- a/tp/t/60macro.t
+++ b/tp/t/60macro.t
@@ -753,6 +753,13 @@ different
 
 @redefineothermacro{@othermacro{}}
 '],
+['macro_before_specific_line_command_args',
+'@macro cpfn
+ cp fn
+@end macro
+
+@syncodeindex@cpfn{}
+'],
 ['macro_in_index_commands',
 '@macro cp
 cp
diff --git a/tp/t/results/macro/macro_before_specific_line_command_args.pl 
b/tp/t/results/macro/macro_before_specific_line_command_args.pl
new file mode 100644
index 0000000000..8719b4a0fd
--- /dev/null
+++ b/tp/t/results/macro/macro_before_specific_line_command_args.pl
@@ -0,0 +1,206 @@
+use vars qw(%result_texis %result_texts %result_trees %result_errors 
+   %result_indices %result_sectioning %result_nodes %result_menus
+   %result_floats %result_converted %result_converted_errors 
+   %result_elements %result_directions_text %result_indices_sort_strings);
+
+use utf8;
+
+$result_trees{'macro_before_specific_line_command_args'} = {
+  'contents' => [
+    {
+      'contents' => [
+        {
+          'args' => [
+            {
+              'text' => 'cpfn',
+              'type' => 'macro_name'
+            }
+          ],
+          'cmdname' => 'macro',
+          'contents' => [
+            {
+              'text' => ' cp fn
+',
+              'type' => 'raw'
+            },
+            {
+              'args' => [
+                {
+                  'contents' => [
+                    {
+                      'text' => 'macro'
+                    }
+                  ],
+                  'info' => {
+                    'spaces_after_argument' => {
+                      'text' => '
+'
+                    }
+                  },
+                  'type' => 'line_arg'
+                }
+              ],
+              'cmdname' => 'end',
+              'extra' => {
+                'text_arg' => 'macro'
+              },
+              'info' => {
+                'spaces_before_argument' => {
+                  'text' => ' '
+                }
+              },
+              'source_info' => {
+                'file_name' => '',
+                'line_nr' => 3,
+                'macro' => ''
+              }
+            }
+          ],
+          'info' => {
+            'arg_line' => ' cpfn
+'
+          },
+          'source_info' => {
+            'file_name' => '',
+            'line_nr' => 1,
+            'macro' => ''
+          }
+        },
+        {
+          'text' => '
+',
+          'type' => 'empty_line'
+        },
+        {
+          'args' => [
+            {
+              'contents' => [
+                {
+                  'source_marks' => [
+                    {
+                      'counter' => 1,
+                      'position' => 5,
+                      'sourcemark_type' => 'macro_expansion',
+                      'status' => 'end'
+                    }
+                  ],
+                  'text' => 'cp fn'
+                }
+              ],
+              'info' => {
+                'spaces_after_argument' => {
+                  'text' => '
+'
+                }
+              },
+              'type' => 'line_arg'
+            }
+          ],
+          'cmdname' => 'syncodeindex',
+          'extra' => {
+            'misc_args' => [
+              'cp',
+              'fn'
+            ]
+          },
+          'info' => {
+            'spaces_before_argument' => {
+              'source_marks' => [
+                {
+                  'counter' => 1,
+                  'element' => {
+                    'args' => [
+                      {
+                        'text' => ''
+                      }
+                    ],
+                    'extra' => {
+                      'name' => 'cpfn'
+                    },
+                    'type' => 'macro_call'
+                  },
+                  'sourcemark_type' => 'macro_expansion',
+                  'status' => 'start'
+                }
+              ],
+              'text' => ' '
+            }
+          },
+          'source_info' => {
+            'file_name' => '',
+            'line_nr' => 5,
+            'macro' => ''
+          }
+        }
+      ],
+      'type' => 'before_node_section'
+    }
+  ],
+  'type' => 'document_root'
+};
+
+$result_texis{'macro_before_specific_line_command_args'} = '@macro cpfn
+ cp fn
+@end macro
+
+@syncodeindex cp fn
+';
+
+
+$result_texts{'macro_before_specific_line_command_args'} = '
+';
+
+$result_errors{'macro_before_specific_line_command_args'} = [];
+
+
+$result_indices{'macro_before_specific_line_command_args'} = {
+  'index_names' => {
+    'cp' => {
+      'in_code' => 1,
+      'merged_in' => 'fn',
+      'name' => 'cp'
+    },
+    'fn' => {
+      'contained_indices' => {
+        'cp' => 1,
+        'fn' => 1
+      },
+      'in_code' => 1,
+      'name' => 'fn'
+    },
+    'ky' => {
+      'contained_indices' => {
+        'ky' => 1
+      },
+      'in_code' => 1,
+      'name' => 'ky'
+    },
+    'pg' => {
+      'contained_indices' => {
+        'pg' => 1
+      },
+      'in_code' => 1,
+      'name' => 'pg'
+    },
+    'tp' => {
+      'contained_indices' => {
+        'tp' => 1
+      },
+      'in_code' => 1,
+      'name' => 'tp'
+    },
+    'vr' => {
+      'contained_indices' => {
+        'vr' => 1
+      },
+      'in_code' => 1,
+      'name' => 'vr'
+    }
+  }
+};
+
+
+$result_floats{'macro_before_specific_line_command_args'} = {};
+
+
+1;



reply via email to

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