texinfo-commits
[Top][All Lists]
Advanced

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

[7564] strip off leading directories for filename in tests


From: gavinsmith0123
Subject: [7564] strip off leading directories for filename in tests
Date: Sat, 24 Dec 2016 09:06:45 +0000 (UTC)

Revision: 7564
          http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=7564
Author:   gavin
Date:     2016-12-24 09:06:45 +0000 (Sat, 24 Dec 2016)
Log Message:
-----------
strip off leading directories for filename in tests

Modified Paths:
--------------
    trunk/ChangeLog
    trunk/tp/Texinfo/Parser.pm
    trunk/tp/t/results/include/macro_and_commands_in_early_commands.pl
    trunk/tp/t/results/include/macro_definition_in_include.pl
    trunk/tp/t/results/include/macro_in_early_commands.pl
    trunk/tp/t/results/include/value_expansion_in_include.pl
    trunk/tp/t/results/sectioning/raiselowersections.pl

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog     2016-12-24 09:05:24 UTC (rev 7563)
+++ trunk/ChangeLog     2016-12-24 09:06:45 UTC (rev 7564)
@@ -1,3 +1,9 @@
+2016-12-24  Gavin Smith  <address@hidden>
+
+       * (_end_line) <@include> If in the tests, strip off leading 
+       directories when recording filename.  This is to be consistent 
+       with what is done in 'parse_texi_file'.
+
 2016-12-20  Gavin Smith  <address@hidden>
 
        * tp/Texinfo/Parser.pm (_parse_def): Instead of calling 'gdt' on 

Modified: trunk/tp/Texinfo/Parser.pm
===================================================================
--- trunk/tp/Texinfo/Parser.pm  2016-12-24 09:05:24 UTC (rev 7563)
+++ trunk/tp/Texinfo/Parser.pm  2016-12-24 09:06:45 UTC (rev 7564)
@@ -3135,6 +3135,9 @@
               binmode($filehandle, ":encoding($self->{'INPUT_PERL_ENCODING'})")
                 if (defined($self->{'INPUT_PERL_ENCODING'}));
               print STDERR "Included $file($filehandle)\n" if 
($self->{'DEBUG'});
+              my ($directories, $suffix);
+              ($file, $directories, $suffix) = fileparse($file)
+                  if ($self->{'TEST'});
               unshift @{$self->{'input'}}, { 
                 'name' => $file,
                 'line_nr' => 0,

Modified: trunk/tp/t/results/include/macro_and_commands_in_early_commands.pl
===================================================================
--- trunk/tp/t/results/include/macro_and_commands_in_early_commands.pl  
2016-12-24 09:05:24 UTC (rev 7563)
+++ trunk/tp/t/results/include/macro_and_commands_in_early_commands.pl  
2016-12-24 09:06:45 UTC (rev 7564)
@@ -376,7 +376,7 @@
 '
           },
           'line_nr' => {
-            'file_name' => 't/include_dir/macro_included.texi',
+            'file_name' => 'macro_included.texi',
             'line_nr' => 1,
             'macro' => ''
           },

Modified: trunk/tp/t/results/include/macro_definition_in_include.pl
===================================================================
--- trunk/tp/t/results/include/macro_definition_in_include.pl   2016-12-24 
09:05:24 UTC (rev 7563)
+++ trunk/tp/t/results/include/macro_definition_in_include.pl   2016-12-24 
09:06:45 UTC (rev 7564)
@@ -34,7 +34,7 @@
 '
       },
       'line_nr' => {
-        'file_name' => 't/include_dir/macro_included.texi',
+        'file_name' => 'macro_included.texi',
         'line_nr' => 1,
         'macro' => ''
       },

Modified: trunk/tp/t/results/include/macro_in_early_commands.pl
===================================================================
--- trunk/tp/t/results/include/macro_in_early_commands.pl       2016-12-24 
09:05:24 UTC (rev 7563)
+++ trunk/tp/t/results/include/macro_in_early_commands.pl       2016-12-24 
09:06:45 UTC (rev 7564)
@@ -461,7 +461,7 @@
 '
           },
           'line_nr' => {
-            'file_name' => 't/include_dir/macro_included.texi',
+            'file_name' => 'macro_included.texi',
             'line_nr' => 1,
             'macro' => ''
           },

Modified: trunk/tp/t/results/include/value_expansion_in_include.pl
===================================================================
--- trunk/tp/t/results/include/value_expansion_in_include.pl    2016-12-24 
09:05:24 UTC (rev 7563)
+++ trunk/tp/t/results/include/value_expansion_in_include.pl    2016-12-24 
09:06:45 UTC (rev 7564)
@@ -202,7 +202,7 @@
               'cmdname' => 'emph',
               'contents' => [],
               'line_nr' => {
-                'file_name' => 't/include_dir/incl-incl.txi',
+                'file_name' => 'incl-incl.txi',
                 'line_nr' => 1,
                 'macro' => ''
               },
@@ -306,7 +306,7 @@
               'cmdname' => 'emph',
               'contents' => [],
               'line_nr' => {
-                'file_name' => 't/include_dir/incl-incl.txi',
+                'file_name' => 'incl-incl.txi',
                 'line_nr' => 1,
                 'macro' => ''
               },
@@ -410,7 +410,7 @@
               'cmdname' => 'emph',
               'contents' => [],
               'line_nr' => {
-                'file_name' => 't/include_dir/incl-incl.txi',
+                'file_name' => 'incl-incl.txi',
                 'line_nr' => 1,
                 'macro' => ''
               },

Modified: trunk/tp/t/results/sectioning/raiselowersections.pl
===================================================================
--- trunk/tp/t/results/sectioning/raiselowersections.pl 2016-12-24 09:05:24 UTC 
(rev 7563)
+++ trunk/tp/t/results/sectioning/raiselowersections.pl 2016-12-24 09:06:45 UTC 
(rev 7564)
@@ -673,7 +673,7 @@
         'spaces_after_command' => {}
       },
       'line_nr' => {
-        'file_name' => 't/include_dir/section_file.texi',
+        'file_name' => 'section_file.texi',
         'line_nr' => 12,
         'macro' => ''
       },
@@ -776,7 +776,7 @@
                 }
               },
               'line_nr' => {
-                'file_name' => 't/include_dir/section_file.texi',
+                'file_name' => 'section_file.texi',
                 'line_nr' => 16,
                 'macro' => ''
               },
@@ -818,7 +818,7 @@
                 'text_arg' => 'menu'
               },
               'line_nr' => {
-                'file_name' => 't/include_dir/section_file.texi',
+                'file_name' => 'section_file.texi',
                 'line_nr' => 17,
                 'macro' => ''
               },
@@ -830,7 +830,7 @@
             'spaces_after_command' => {}
           },
           'line_nr' => {
-            'file_name' => 't/include_dir/section_file.texi',
+            'file_name' => 'section_file.texi',
             'line_nr' => 15,
             'macro' => ''
           },
@@ -852,7 +852,7 @@
       },
       'level' => 2,
       'line_nr' => {
-        'file_name' => 't/include_dir/section_file.texi',
+        'file_name' => 'section_file.texi',
         'line_nr' => 13,
         'macro' => ''
       },
@@ -902,7 +902,7 @@
         'spaces_after_command' => {}
       },
       'line_nr' => {
-        'file_name' => 't/include_dir/section_file.texi',
+        'file_name' => 'section_file.texi',
         'line_nr' => 19,
         'macro' => ''
       },
@@ -1005,7 +1005,7 @@
                 }
               },
               'line_nr' => {
-                'file_name' => 't/include_dir/section_file.texi',
+                'file_name' => 'section_file.texi',
                 'line_nr' => 23,
                 'macro' => ''
               },
@@ -1047,7 +1047,7 @@
                 'text_arg' => 'menu'
               },
               'line_nr' => {
-                'file_name' => 't/include_dir/section_file.texi',
+                'file_name' => 'section_file.texi',
                 'line_nr' => 24,
                 'macro' => ''
               },
@@ -1059,7 +1059,7 @@
             'spaces_after_command' => {}
           },
           'line_nr' => {
-            'file_name' => 't/include_dir/section_file.texi',
+            'file_name' => 'section_file.texi',
             'line_nr' => 22,
             'macro' => ''
           },
@@ -1081,7 +1081,7 @@
       },
       'level' => 3,
       'line_nr' => {
-        'file_name' => 't/include_dir/section_file.texi',
+        'file_name' => 'section_file.texi',
         'line_nr' => 20,
         'macro' => ''
       },
@@ -1131,7 +1131,7 @@
         'spaces_after_command' => {}
       },
       'line_nr' => {
-        'file_name' => 't/include_dir/section_file.texi',
+        'file_name' => 'section_file.texi',
         'line_nr' => 26,
         'macro' => ''
       },
@@ -1230,7 +1230,7 @@
       },
       'level' => 4,
       'line_nr' => {
-        'file_name' => 't/include_dir/section_file.texi',
+        'file_name' => 'section_file.texi',
         'line_nr' => 27,
         'macro' => ''
       },




reply via email to

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