5
:Contact: goodger@users.sourceforge.net
6
:Revision: $Revision: 1.2 $
7
:Date: $Date: 2002/04/25 03:43:15 $
8
:Copyright: This module has been placed in the public domain.
13
from __init__ import DocutilsTestSupport
16
s = DocutilsTestSupport.ParserTestSuite()
17
s.generateTests(totest)
22
totest['option_lists'] = [
50
<option_argument delimiter=" ">
60
<option_argument delimiter=" ">
70
--bbbb=file option --bbbb
71
--cccc name option --cccc
72
--d-e-f-g option --d-e-f-g
73
--h_i_j_k option --h_i_j_k
93
<option_argument delimiter="=">
103
<option_argument delimiter=" ">
126
Old GNU-style options:
137
Old GNU-style options:
152
<option_argument delimiter=" ">
162
<option_argument delimiter=" ">
169
VMS/DOS-style options:
174
/DDD string option /DDD
180
VMS/DOS-style options:
195
<option_argument delimiter=" ">
213
<option_argument delimiter=" ">
223
<option_argument delimiter="=">
230
Mixed short, long, and VMS/DOS options:
233
--bbbb=file option -bbbb
235
--dddd name option --dddd
242
Mixed short, long, and VMS/DOS options:
257
<option_argument delimiter="=">
275
<option_argument delimiter=" ">
285
<option_argument delimiter=" ">
295
<option_argument delimiter=" ">
304
-a, --aaaa, /A option -a, --aaaa, /A
305
-b file, --bbbb=file, /B file option -b, --bbbb, /B
325
option -a, --aaaa, /A
331
<option_argument delimiter=" ">
336
<option_argument delimiter="=">
341
<option_argument delimiter=" ">
345
option -b, --bbbb, /B
348
Multiple lines in descriptions, aligned:
352
-b file option -b, line 1
358
Multiple lines in descriptions, aligned:
374
<option_argument delimiter=" ">
382
Multiple lines in descriptions, not aligned:
386
-b file option -b, line 1
392
Multiple lines in descriptions, not aligned:
408
<option_argument delimiter=" ">
416
Descriptions begin on next line:
428
Descriptions begin on next line:
444
<option_argument delimiter=" ">
452
Multiple body elements in descriptions:
465
Multiple body elements in descriptions:
482
<option_argument delimiter=" ">
492
empty item above, no blank line
498
empty item above, no blank line
501
An option list using equals:
503
--long1=arg1 Description 1
504
--long2=arg2 Description 2
506
An option list using spaces:
508
--long1 arg1 Description 1
509
--long2 arg2 Description 2
511
An option list using mixed delimiters:
513
--long1=arg1 Description 1
514
--long2 arg2 Description 2
516
An option list using mixed delimiters in one line:
518
--long1=arg1, --long2 arg2 Description
523
An option list using equals:
530
<option_argument delimiter="=">
540
<option_argument delimiter="=">
546
An option list using spaces:
553
<option_argument delimiter=" ">
563
<option_argument delimiter=" ">
569
An option list using mixed delimiters:
576
<option_argument delimiter="=">
586
<option_argument delimiter=" ">
592
An option list using mixed delimiters in one line:
599
<option_argument delimiter="=">
604
<option_argument delimiter=" ">
613
--option=arg arg too many arguments
615
--option=arg,arg not supported (yet?)
617
--option=arg=arg too many arguments
619
--option arg arg too many arguments
621
-a letter arg2 too many arguments
623
/A letter arg2 too many arguments
625
--option= argument missing
627
--=argument option missing
630
- this should be a bullet list item
632
These next ones should be simple paragraphs:
647
--option=arg arg too many arguments
649
--option=arg,arg not supported (yet?)
651
--option=arg=arg too many arguments
653
--option arg arg too many arguments
655
-a letter arg2 too many arguments
657
/A letter arg2 too many arguments
659
--option= argument missing
661
--=argument option missing
663
-- everything missing
664
<bullet_list bullet="-">
667
this should be a bullet list item
669
These next ones should be simple paragraphs:
681
if __name__ == '__main__':
683
unittest.main(defaultTest='suite')