texinfo-commits
[Top][All Lists]
Advanced

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

texinfo/tp TODO t/02coverage.t t/03coverage_bra...


From: Patrice Dumas
Subject: texinfo/tp TODO t/02coverage.t t/03coverage_bra...
Date: Sun, 24 Oct 2010 10:14:51 +0000

CVSROOT:        /sources/texinfo
Module name:    texinfo
Changes by:     Patrice Dumas <pertusus>        10/10/24 10:14:50

Modified files:
        tp             : TODO 
        tp/t           : 02coverage.t 03coverage_braces.t 16raw.t 
Added files:
        tp/t/results/coverage: unknown_commands.pl 
        tp/t/results/coverage_braces: unknown_command_with_braces.pl 
        tp/t/results/raw: verbatim_not_closed.pl 

Log message:
        Finish testing of invalid constructs relevant for the Parser.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/TODO?cvsroot=texinfo&r1=1.38&r2=1.39
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/t/02coverage.t?cvsroot=texinfo&r1=1.21&r2=1.22
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/t/03coverage_braces.t?cvsroot=texinfo&r1=1.9&r2=1.10
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/t/16raw.t?cvsroot=texinfo&r1=1.9&r2=1.10
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/t/results/coverage/unknown_commands.pl?cvsroot=texinfo&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/t/results/coverage_braces/unknown_command_with_braces.pl?cvsroot=texinfo&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/texinfo/tp/t/results/raw/verbatim_not_closed.pl?cvsroot=texinfo&rev=1.1

Patches:
Index: TODO
===================================================================
RCS file: /sources/texinfo/texinfo/tp/TODO,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -b -r1.38 -r1.39
--- TODO        24 Oct 2010 10:02:42 -0000      1.38
+++ TODO        24 Oct 2010 10:14:49 -0000      1.39
@@ -15,8 +15,6 @@
 @heading A heading
 @end example
 
-test invalid, especially commands not closed/bad nesting
-
 test empty line in block or brace command in menu description.
 
 in t/57invalid_nestings.t in_table, no warning for bad stuff on @item line.
@@ -64,6 +62,14 @@
 @@verbatiminclude dot.
 @verbatiminclude ./formatting/simplest.texi
 
+tests in test/invalid, not incorporated
+author_outside_titlepage_quotation.texi
+bad_documentencoding.texi
+direntry_dircategory_after_first_node.texi
+double_top_section.texi
+error_in_footnote_caption.texi
+tex_in_copying.texi               (this is not invalid)
+
 done:
 formatting/def_end_of_line.texi
 formatting/def_end_of_line_footnote.texi
@@ -100,7 +106,7 @@
 invalid/node_in_copying.texi
 invalid/node_too_much_arguments.texi
 invalid/not_closed_in_menu.texi
-invalid/recursive_copying.texi
+invalid/recursive_copying.texi             (but not the expansion)
 invalid/style_not_closed_in_cartouche.texi
 invalid/style_not_closed_in_table_line.texi
 invalid/tab_in_index.texi                  (but not the printindex)
@@ -108,6 +114,8 @@
 invalid/titlepage_not_closed.texi
 invalid/unclosed_verb_line_commands.texi   (but the result is different since
                                             ignored until end of file).
+invalid/unknown_command_with_braces.texi
 invalid/verb_and_char_end_of_line.texi
 invalid/verb_end_of_line.texi
 invalid/verb_not_closed.texi
+invalid/verbatim_not_closed.texi

Index: t/02coverage.t
===================================================================
RCS file: /sources/texinfo/texinfo/tp/t/02coverage.t,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -b -r1.21 -r1.22
--- t/02coverage.t      23 Oct 2010 22:37:42 -0000      1.21
+++ t/02coverage.t      24 Oct 2010 10:14:49 -0000      1.22
@@ -266,6 +266,10 @@
 '@group
 
 text in group
+'],
+['unknown_commands',
+'@unknwon
address@hidden
 ']
 );
 

Index: t/03coverage_braces.t
===================================================================
RCS file: /sources/texinfo/texinfo/tp/t/03coverage_braces.t,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- t/03coverage_braces.t       24 Oct 2010 09:06:55 -0000      1.9
+++ t/03coverage_braces.t       24 Oct 2010 10:14:49 -0000      1.10
@@ -53,7 +53,20 @@
 '],
 ['math_not_closed','@math{\delta + 2'],
 ['math_bracketed_not_closed','@math{{x^i}\over{\tan '],
-['math_bracketed_inside_not_closed','@math{{x^i}\over{\tan}']
+['math_bracketed_inside_not_closed','@math{{x^i}\over{\tan}'],
+['unknown_command_with_braces',
+'Unknown thing @thing{}
+
+Unknown macro @unknown{ first paragraph
+
+second paragraph}
+
address@hidden first paragraph
+
+second paragraph
+
+third}
+']
 );
 
 our ($arg_test_case, $arg_generate, $arg_debug);

Index: t/16raw.t
===================================================================
RCS file: /sources/texinfo/texinfo/tp/t/16raw.t,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- t/16raw.t   24 Oct 2010 09:39:12 -0000      1.9
+++ t/16raw.t   24 Oct 2010 10:14:49 -0000      1.10
@@ -67,6 +67,14 @@
 '@tex
 
 This is some \LaTeX{}
+'],
+['verbatim_not_closed',
+'@verbatim
+
+some verbatim @
+
address@hidden
+
 ']
 );
 

Index: t/results/coverage/unknown_commands.pl
===================================================================
RCS file: t/results/coverage/unknown_commands.pl
diff -N t/results/coverage/unknown_commands.pl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ t/results/coverage/unknown_commands.pl      24 Oct 2010 10:14:49 -0000      
1.1
@@ -0,0 +1,58 @@
+use vars qw(%result_texis %result_texts %result_trees %result_errors);
+
+$result_trees{'unknown_commands'} = {
+  'contents' => [
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => '
+'
+        },
+        {
+          'parent' => {},
+          'text' => '#
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    }
+  ],
+  'type' => 'text_root'
+};
+$result_trees{'unknown_commands'}{'contents'}[0]{'contents'}[0]{'parent'} = 
$result_trees{'unknown_commands'}{'contents'}[0];
+$result_trees{'unknown_commands'}{'contents'}[0]{'contents'}[1]{'parent'} = 
$result_trees{'unknown_commands'}{'contents'}[0];
+$result_trees{'unknown_commands'}{'contents'}[0]{'parent'} = 
$result_trees{'unknown_commands'};
+
+$result_texis{'unknown_commands'} = '
+#
+';
+
+
+$result_texts{'unknown_commands'} = '
+#
+';
+
+$result_errors{'unknown_commands'} = [
+  {
+    'error_line' => ':1: Unknown command `unknwon\'
+',
+    'file_name' => '',
+    'line_nr' => 1,
+    'macro' => '',
+    'text' => 'Unknown command `unknwon\'',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':2: Unexpected @
+',
+    'file_name' => '',
+    'line_nr' => 2,
+    'macro' => '',
+    'text' => 'Unexpected @',
+    'type' => 'error'
+  }
+];
+
+

Index: t/results/coverage_braces/unknown_command_with_braces.pl
===================================================================
RCS file: t/results/coverage_braces/unknown_command_with_braces.pl
diff -N t/results/coverage_braces/unknown_command_with_braces.pl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ t/results/coverage_braces/unknown_command_with_braces.pl    24 Oct 2010 
10:14:50 -0000      1.1
@@ -0,0 +1,233 @@
+use vars qw(%result_texis %result_texts %result_trees %result_errors);
+
+$result_trees{'unknown_command_with_braces'} = {
+  'contents' => [
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => 'Unknown thing 
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    },
+    {
+      'parent' => {},
+      'text' => '
+',
+      'type' => 'empty_line'
+    },
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => 'Unknown macro  first paragraph
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    },
+    {
+      'parent' => {},
+      'text' => '
+',
+      'type' => 'empty_line'
+    },
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => 'second paragraph
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    },
+    {
+      'parent' => {},
+      'text' => '
+',
+      'type' => 'empty_line'
+    },
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => ' first paragraph
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    },
+    {
+      'parent' => {},
+      'text' => '
+',
+      'type' => 'empty_line'
+    },
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => 'second paragraph
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    },
+    {
+      'parent' => {},
+      'text' => '
+',
+      'type' => 'empty_line'
+    },
+    {
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => 'third
+'
+        }
+      ],
+      'parent' => {},
+      'type' => 'paragraph'
+    }
+  ],
+  'type' => 'text_root'
+};
+$result_trees{'unknown_command_with_braces'}{'contents'}[0]{'contents'}[0]{'parent'}
 = $result_trees{'unknown_command_with_braces'}{'contents'}[0];
+$result_trees{'unknown_command_with_braces'}{'contents'}[0]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[1]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[2]{'contents'}[0]{'parent'}
 = $result_trees{'unknown_command_with_braces'}{'contents'}[2];
+$result_trees{'unknown_command_with_braces'}{'contents'}[2]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[3]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[4]{'contents'}[0]{'parent'}
 = $result_trees{'unknown_command_with_braces'}{'contents'}[4];
+$result_trees{'unknown_command_with_braces'}{'contents'}[4]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[5]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[6]{'contents'}[0]{'parent'}
 = $result_trees{'unknown_command_with_braces'}{'contents'}[6];
+$result_trees{'unknown_command_with_braces'}{'contents'}[6]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[7]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[8]{'contents'}[0]{'parent'}
 = $result_trees{'unknown_command_with_braces'}{'contents'}[8];
+$result_trees{'unknown_command_with_braces'}{'contents'}[8]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[9]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+$result_trees{'unknown_command_with_braces'}{'contents'}[10]{'contents'}[0]{'parent'}
 = $result_trees{'unknown_command_with_braces'}{'contents'}[10];
+$result_trees{'unknown_command_with_braces'}{'contents'}[10]{'parent'} = 
$result_trees{'unknown_command_with_braces'};
+
+$result_texis{'unknown_command_with_braces'} = 'Unknown thing 
+
+Unknown macro  first paragraph
+
+second paragraph
+
+ first paragraph
+
+second paragraph
+
+third
+';
+
+
+$result_texts{'unknown_command_with_braces'} = 'Unknown thing 
+
+Unknown macro  first paragraph
+
+second paragraph
+
+ first paragraph
+
+second paragraph
+
+third
+';
+
+$result_errors{'unknown_command_with_braces'} = [
+  {
+    'error_line' => ':1: Unknown command `thing\'
+',
+    'file_name' => '',
+    'line_nr' => 1,
+    'macro' => '',
+    'text' => 'Unknown command `thing\'',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':1: Misplaced {
+',
+    'file_name' => '',
+    'line_nr' => 1,
+    'macro' => '',
+    'text' => 'Misplaced {',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':1: Misplaced }
+',
+    'file_name' => '',
+    'line_nr' => 1,
+    'macro' => '',
+    'text' => 'Misplaced }',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':3: Unknown command `unknown\'
+',
+    'file_name' => '',
+    'line_nr' => 3,
+    'macro' => '',
+    'text' => 'Unknown command `unknown\'',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':3: Misplaced {
+',
+    'file_name' => '',
+    'line_nr' => 3,
+    'macro' => '',
+    'text' => 'Misplaced {',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':5: Misplaced }
+',
+    'file_name' => '',
+    'line_nr' => 5,
+    'macro' => '',
+    'text' => 'Misplaced }',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':7: Unknown command `unknown2\'
+',
+    'file_name' => '',
+    'line_nr' => 7,
+    'macro' => '',
+    'text' => 'Unknown command `unknown2\'',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':7: Misplaced {
+',
+    'file_name' => '',
+    'line_nr' => 7,
+    'macro' => '',
+    'text' => 'Misplaced {',
+    'type' => 'error'
+  },
+  {
+    'error_line' => ':11: Misplaced }
+',
+    'file_name' => '',
+    'line_nr' => 11,
+    'macro' => '',
+    'text' => 'Misplaced }',
+    'type' => 'error'
+  }
+];
+
+

Index: t/results/raw/verbatim_not_closed.pl
===================================================================
RCS file: t/results/raw/verbatim_not_closed.pl
diff -N t/results/raw/verbatim_not_closed.pl
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ t/results/raw/verbatim_not_closed.pl        24 Oct 2010 10:14:50 -0000      
1.1
@@ -0,0 +1,86 @@
+use vars qw(%result_texis %result_texts %result_trees %result_errors);
+
+$result_trees{'verbatim_not_closed'} = {
+  'contents' => [
+    {
+      'cmdname' => 'verbatim',
+      'contents' => [
+        {
+          'parent' => {},
+          'text' => '
+',
+          'type' => 'empty_line_after_command'
+        },
+        {
+          'parent' => {},
+          'text' => '
+',
+          'type' => 'raw'
+        },
+        {
+          'parent' => {},
+          'text' => 'some verbatim @
+',
+          'type' => 'raw'
+        },
+        {
+          'parent' => {},
+          'text' => '
+',
+          'type' => 'raw'
+        },
+        {
+          'parent' => {},
+          'text' => '@macro
+',
+          'type' => 'raw'
+        },
+        {
+          'parent' => {},
+          'text' => '
+',
+          'type' => 'raw'
+        }
+      ],
+      'parent' => {}
+    }
+  ],
+  'type' => 'text_root'
+};
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'contents'}[0]{'parent'} = 
$result_trees{'verbatim_not_closed'}{'contents'}[0];
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'contents'}[1]{'parent'} = 
$result_trees{'verbatim_not_closed'}{'contents'}[0];
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'contents'}[2]{'parent'} = 
$result_trees{'verbatim_not_closed'}{'contents'}[0];
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'contents'}[3]{'parent'} = 
$result_trees{'verbatim_not_closed'}{'contents'}[0];
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'contents'}[4]{'parent'} = 
$result_trees{'verbatim_not_closed'}{'contents'}[0];
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'contents'}[5]{'parent'} = 
$result_trees{'verbatim_not_closed'}{'contents'}[0];
+$result_trees{'verbatim_not_closed'}{'contents'}[0]{'parent'} = 
$result_trees{'verbatim_not_closed'};
+
+$result_texis{'verbatim_not_closed'} = '@verbatim
+
+some verbatim @
+
address@hidden
+
address@hidden verbatim';
+
+
+$result_texts{'verbatim_not_closed'} = '
+some verbatim @
+
address@hidden
+
+';
+
+$result_errors{'verbatim_not_closed'} = [
+  {
+    'error_line' => ':6: No matching address@hidden verbatim\'
+',
+    'file_name' => '',
+    'line_nr' => 6,
+    'macro' => '',
+    'text' => 'No matching address@hidden verbatim\'',
+    'type' => 'error'
+  }
+];
+
+



reply via email to

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