-
Notifications
You must be signed in to change notification settings - Fork 8
/
testhtml.html
4481 lines (4213 loc) · 159 KB
/
testhtml.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang="en">
<head>
<title>SAM Parser Tests</title>
<meta charset = "UTF-8">
</head>
<body>
<!-- This file is part of the SPFE Open Toolkit. See the accompanying license.txt file -->
<!-- for applicable licenses. -->
<!-- (c) Copyright Analecta Communications Inc. 2015 All Rights Reserved. -->
<!-- Need test for unicode characters and numbers in names. -->
<div class="tests" lang="en">
<h1 class="title">SAM Parser Tests</h1>
<div class="description">
<p class="p">This document is the output of the test document processed by test.xslt. That stylesheet attempt to validate the outcome of tests by generating a string version of the markup under the <code class="code" data-language="sam">markup:</code> heading and comparing it to the text of the expected result as shown under the <code class="code">result:</code> heading in the test file. This is not a perfect test. Two issues are known:</p>
<ol class="ol">
<li class="li">
<p class="p">Test are done on whitespace normalized versions of the XML markup strings. As such, they do not validly test situations where whitespace should be retained, such as in codeblocks and at the beginning of lines.</p>
</li>
<li class="li">
<p class="p">The SAM parser outputs attributes in alphabetical order. (From an XML point of view, the order of attributes does not matter.) Test should be written such that the attributes in the <code class="code">result:</code> section are in alphabetical order. If not, the test will fail even though the XML is semantically identical.</p>
</li>
</ol>
<p class="p">When running this test you should receive one SAM Parser Warning:</p>
<pre class="codeblock" data-language="terminal"><code class="codeblock" data-language="terminal">SAM parser warning: Unannotated phrase found: {should be reported} If you are trying to insert curly braces into the document, use \{should be reported}.
</code></pre>
<p class="p">This is a test to make sure unannotated phrases are being reported correctly.</p>
<p class="p">The following lines exist to anchor ids used for idref examples in the tests:</p>
<pre class="line" id="cit">Cit</pre>
<pre class="line" id="MobyDick">Moby Dick</pre>
<pre class="line" id="bing">bing</pre>
<pre class="line" id="my-table">my-table</pre>
</div>
<div class="test">
<h2 class="title">Includes</h2>
<div class="description">
<p class="p">Include content from another SAM file.</p>
</div>
<div class="case">
<h3 class="title">Local only annotations</h3>
<div class="description">
<p class="p">A local-only annotation is one which applies only to the current phrase. It is not taken into consideration in annotation lookup, so the lookup search will proceed to the next phrase with the same text. Annotation lookup will occur for a phrase with a local-only annotation, and the local annotation will be added to the looked up annotations, if any.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">Testing {XML}(language) testing {XML}+(index) testing {XML}.
</code></pre>
</div>
<div class="markup">
<p class="p">Testing <span class="phrase"><span class="annotation" data-annotation-type="language">XML</span></span> testing <span class="phrase"><span class="annotation" data-annotation-type="index"><span class="annotation" data-annotation-type="language">XML</span></span></span> testing <span class="phrase"><span class="annotation" data-annotation-type="language">XML</span></span>.</p>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><p>Testing <phrase><annotation type="language">XML</annotation></phrase> testing <phrase><annotation type="index"><annotation type="language">XML</annotation></annotation></phrase> testing <phrase><annotation type="language">XML</annotation></phrase>.</p>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Simple include</h3>
<div class="description">
<p class="p">An include statement.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam"><<<(includeme.sam)
</code></pre>
</div>
<div class="markup">
<div class="message">
<h5 class="title">Hello World.</h5>
<p class="p">This is the "include" test -- file.</p>
<table class="grid">
<tr class="row">
<td class="cell">foo</td>
<td class="cell">bar</td>
</tr>
<tr class="row">
<td class="cell">baz</td>
<td class="cell">bat</td>
</tr>
</table>
<p class="p">Annotation lookup test: <span class="phrase"><span class="annotation" data-annotation-type="test">test phrase</span></span>.</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><message>
<title>Hello World.</title>
<p>This is the "include" test -- file.</p>
<grid>
<row>
<cell>foo</cell>
<cell>bar</cell>
</row>
<row>
<cell>baz</cell>
<cell>bat</cell>
</row>
</grid>
<p>Annotation lookup test: <phrase><annotation type="test">test phrase</annotation></phrase>.</p>
</message>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Nested includes</h3>
<div class="description">
<p class="p">Including a file that itself includes a file.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam"><<<(includeme1.sam)
</code></pre>
</div>
<div class="markup">
<div class="message">
<p class="p">This file includes another file.</p>
<p class="p">Nested includes work! Yipee!</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><message>
<p>This file includes another file.</p>
<p>Nested includes work! Yipee!</p>
</message>
</code></pre>
</div>
</div>
</div>
<div class="test">
<h2 class="title">Blocks</h2>
<div class="description">
<p class="p">Blocks are the basic building block of a SAM file. This whole document is a test case for blocks.</p>
</div>
<div class="case">
<h3 class="title">Language metadata</h3>
<div class="description">
<p class="p">A block with language metadata.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">section:(!es)
Feliz Navidad
</code></pre>
</div>
<div class="markup">
<div class="section" lang="es">
<p class="p">Feliz Navidad</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><section xml:lang="es">
<p>Feliz Navidad</p>
</section>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Citations</h3>
<div class="description">
<p class="p">A citation on the block.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">section:(!es)[Mother McCree] Greeting
Feliz Navidad
</code></pre>
</div>
<div class="markup">
<div class="section" lang="es">
<cite>Mother McCree</cite>
<h4 class="title">Greeting</h4>
<p class="p">Feliz Navidad</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><section xml:lang="es">
<citation>Mother McCree</citation>
<title>Greeting</title>
<p>Feliz Navidad</p>
</section>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Escaping block syntax</h3>
<div class="description">
<p class="p">Escape colon to prevent single word followed by colon being recognized as a block.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">and\:
</code></pre>
</div>
<div class="markup">
<p class="p">and:</p>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><p>and:</p>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Complex block structure</h3>
<div class="description">
<p class="p">A complex block with various structures inside.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">document:
head:(#foo)
foo: barney {and}(conjunction) betty
baz: bat
$name=fred {and}(conjunction) wilma
history:: date, author, comment, status
2014-06-23, mbaker, New\, Topic, In progress
2016-07-01, mbaker, Revision, In progress
index:: type, term
feature, fragment
feature, fragments
body: How Fragments Work
Stuff on how fragments work.
</code></pre>
</div>
<div class="markup">
<div class="document">
<div class="head" data-name="foo">
<div class="foo">barney <span class="phrase"><span class="annotation" data-annotation-type="conjunction">and</span></span> betty</div>
<div class="baz">bat</div>
<div class="variable" data-name="name" hidden>fred <span class="phrase"><span class="annotation" data-annotation-type="conjunction">and</span></span> wilma</div>
<table class="history">
<thead class="recordset-header">
<tr class="recordset-header-row">
<th class ="recordset-field" data-field-name="date"></th >
<th class ="recordset-field" data-field-name="author"></th >
<th class ="recordset-field" data-field-name="comment"></th >
<th class ="recordset-field" data-field-name="status"></th >
</tr>
</thead>
<tbody class="recordset-body">
<tr class="record">
<td class="record-field" data-field-name="date">2014-06-23</td>
<td class="record-field" data-field-name="author">mbaker</td>
<td class="record-field" data-field-name="comment">New, Topic</td>
<td class="record-field" data-field-name="status">In progress</td>
</tr>
<tr class="record">
<td class="record-field" data-field-name="date">2016-07-01</td>
<td class="record-field" data-field-name="author">mbaker</td>
<td class="record-field" data-field-name="comment">Revision</td>
<td class="record-field" data-field-name="status">In progress</td>
</tr>
</tbody>
</table>
<table class="index">
<thead class="recordset-header">
<tr class="recordset-header-row">
<th class ="recordset-field" data-field-name="type"></th >
<th class ="recordset-field" data-field-name="term"></th >
</tr>
</thead>
<tbody class="recordset-body">
<tr class="record">
<td class="record-field" data-field-name="type">feature</td>
<td class="record-field" data-field-name="term">fragment</td>
</tr>
<tr class="record">
<td class="record-field" data-field-name="type">feature</td>
<td class="record-field" data-field-name="term">fragments</td>
</tr>
</tbody>
</table>
</div>
<div class="body">
<h4 class="title">How Fragments Work</h4>
<p class="p">Stuff on how fragments work.</p>
</div>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><document>
<head name="foo">
<foo>barney <phrase><annotation type="conjunction">and</annotation></phrase> betty</foo>
<baz>bat</baz>
<variable name="name">fred <phrase><annotation type="conjunction">and</annotation></phrase> wilma</variable>
<history>
<record>
<date>2014-06-23</date>
<author>mbaker</author>
<comment>New, Topic</comment>
<status>In progress</status>
</record>
<record>
<date>2016-07-01</date>
<author>mbaker</author>
<comment>Revision</comment>
<status>In progress</status>
</record>
</history>
<index>
<record>
<type>feature</type>
<term>fragment</term>
</record>
<record>
<type>feature</type>
<term>fragments</term>
</record>
</index>
</head>
<body>
<title>How Fragments Work</title>
<p>Stuff on how fragments work.</p>
</body>
</document>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Paragraph with colon in first word</h3>
<div class="description">
<p class="p">Case related to issue #94.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">article: Foo
foo{bar}(http://www.example.com/).
`foo::bar` baz.
</code></pre>
</div>
<div class="markup">
<div class="article">
<h4 class="title">Foo</h4>
<p class="p">foo<span class="phrase"><a href=http://www.example.com/ class="link">bar</a></span>.</p>
<p class="p"><code class="code">foo::bar</code> baz.</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><article>
<title>Foo</title>
<p>foo<phrase><annotation type="link" specifically="http://www.example.com/">bar</annotation></phrase>.</p>
<p><code>foo::bar</code> baz.</p>
</article>
</code></pre>
</div>
</div>
</div>
<!-- FIXME: Need tests for comments. -->
<div class="test">
<h2 class="title">Remarks</h2>
<div class="description">
<p class="p">Remarks are a type of comment that is attributed to an author and is used for commenting editorially on the document.</p>
</div>
<div class="case">
<h3 class="title">Simple remark</h3>
<div class="description">
<p class="p">Just a simple remark. Nothing fancy.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">!!!(mbaker)
This is a remark.
</code></pre>
</div>
<div class="markup">
<div class="remark" data-attribution="mbaker">
<p class="p">This is a remark.</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><remark attribution="mbaker">
<p>This is a remark.</p>
</remark>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Complex remark</h3>
<div class="description">
<p class="p">A little bit more complex.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">!!!(Charles André Joseph Marie de Gaulle !@#$%^&*(((({}":<>)(*cdg1)(!fr)
This is a remark.
</code></pre>
</div>
<div class="markup">
<div class="remark" data-attribution="Charles André Joseph Marie de Gaulle !@#$%^&*(((({}":<>" id="cdg1" lang="fr">
<p class="p">This is a remark.</p>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><remark attribution="Charles André Joseph Marie de Gaulle !@#$%^&amp;*(((({}&quot;:&lt;&gt;" id="cdg1" xml:lang="fr">
<p>This is a remark.</p>
</remark>
</code></pre>
</div>
</div>
</div>
<div class="test">
<h2 class="title">Fields</h2>
<div class="description">
<p class="p">A field is a block without children. A field value does not get wrapped in a title element. It is simple the value of the field.</p>
</div>
<div class="case">
<h3 class="title">Nested fields</h3>
<div class="description">
<p class="p">Nested fields. Anything with a child, of course, is a block, not a field.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">address:
name: Fred Flintstone
address: Bedrock
era: Stone Age
</code></pre>
</div>
<div class="markup">
<div class="address">
<div class="name">Fred Flintstone</div>
<div class="address">Bedrock</div>
<div class="era">Stone Age</div>
</div>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><address>
<name>Fred Flintstone</name>
<address>Bedrock</address>
<era>Stone Age</era>
</address>
</code></pre>
</div>
</div>
</div>
<div class="test">
<h2 class="title">Paragraphs</h2>
<div class="description">
<p class="p">A paragraph is a block of text over consecutive lines.</p>
</div>
<div class="case">
<h3 class="title">Paragraph</h3>
<div class="description">
<p class="p">A simple multi-line paragraph ending with a blank space.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">Wafting zephyrs
quickly vexed
Jumbo.
</code></pre>
</div>
<div class="markup">
<p class="p">Wafting zephyrs quickly vexed Jumbo.</p>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><p>Wafting zephyrs quickly vexed Jumbo.</p>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">With annotated phrase</h3>
<div class="description">
<p class="p">A paragraph over multiple lines with an annotated phrase.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">This is a {paragraph}(foo)
that wraps across
multiple lines.
</code></pre>
</div>
<div class="markup">
<p class="p">This is a <span class="phrase"><span class="annotation" data-annotation-type="foo">paragraph</span></span> that wraps across multiple lines.</p>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><p>This is a <phrase><annotation type="foo">paragraph</annotation></phrase> that wraps across multiple lines.</p>
</code></pre>
</div>
</div>
</div>
<div class="test">
<h2 class="title">Ordered lists</h2>
<div class="description">
<p class="p">Ordered lists are created by starting a line with a number followed by a period. Exact numbers are not retained.</p>
</div>
<div class="case">
<h3 class="title">Ordered list with spaces</h3>
<div class="description">
<p class="p">Ordered lists can have blank lines between the items.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">0. One
0. Two
99999. Three
</code></pre>
</div>
<div class="markup">
<ol class="ol">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two</p>
</li>
<li class="li">
<p class="p">Three</p>
</li>
</ol>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ol>
<li>
<p>One</p>
</li>
<li>
<p>Two</p>
</li>
<li>
<p>Three</p>
</li>
</ol>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Ordered list no spaces</h3>
<div class="description">
<p class="p">List are also recognized without space between items. List items can wrap to another line if more indented than the number. Additional paragraphs can be included if more indented than the number.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">0. One
0. Two this
paragraph wraps.
This is another para in the list item.
99999. Three
</code></pre>
</div>
<div class="markup">
<ol class="ol">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two this paragraph wraps.</p>
<p class="p">This is another para in the list item.</p>
</li>
<li class="li">
<p class="p">Three</p>
</li>
</ol>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ol>
<li>
<p>One</p>
</li>
<li>
<p>Two this paragraph wraps.</p>
<p>This is another para in the list item.</p>
</li>
<li>
<p>Three</p>
</li>
</ol>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Ordered list mixed spacing</h3>
<div class="description">
<p class="p">Ordered list with inconsistent spacing.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">0. One
0. Two
99999. Three
7. Four
</code></pre>
</div>
<div class="markup">
<ol class="ol">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two</p>
</li>
<li class="li">
<p class="p">Three</p>
</li>
<li class="li">
<p class="p">Four</p>
</li>
</ol>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ol>
<li>
<p>One</p>
</li>
<li>
<p>Two</p>
</li>
<li>
<p>Three</p>
</li>
<li>
<p>Four</p>
</li>
</ol>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Nested ordered list with spaces</h3>
<div class="description">
<p class="p">Ordered lists at different indents, with spaces between lines.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">0. One
0. Two x
5. Two and a quarter x
6. Two and a half
9. Two and three quarters
99999. Three
7. Four
</code></pre>
</div>
<div class="markup">
<ol class="ol">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two x</p>
<ol class="ol">
<li class="li">
<p class="p">Two and a quarter x</p>
</li>
<li class="li">
<p class="p">Two and a half</p>
</li>
<li class="li">
<p class="p">Two and three quarters</p>
</li>
</ol>
</li>
<li class="li">
<p class="p">Three</p>
</li>
<li class="li">
<p class="p">Four</p>
</li>
</ol>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ol>
<li>
<p>One</p>
</li>
<li>
<p>Two x</p>
<ol>
<li>
<p>Two and a quarter x</p>
</li>
<li>
<p>Two and a half</p>
</li>
<li>
<p>Two and three quarters</p>
</li>
</ol>
</li>
<li>
<p>Three</p>
</li>
<li>
<p>Four</p>
</li>
</ol>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Nested ordered lists with no spaces</h3>
<div class="description">
<p class="p">Ordered lists at different indents, with no spaces between lines.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">0. One
0. Two z
5. Two and a quarter z
6. Two and a half
9. Two and three quarters
99999. Three
7. Four
</code></pre>
</div>
<div class="markup">
<ol class="ol">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two z</p>
<ol class="ol">
<li class="li">
<p class="p">Two and a quarter z</p>
</li>
<li class="li">
<p class="p">Two and a half</p>
</li>
<li class="li">
<p class="p">Two and three quarters</p>
</li>
</ol>
</li>
<li class="li">
<p class="p">Three</p>
</li>
<li class="li">
<p class="p">Four</p>
</li>
</ol>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ol>
<li>
<p>One</p>
</li>
<li>
<p>Two z</p>
<ol>
<li>
<p>Two and a quarter z</p>
</li>
<li>
<p>Two and a half</p>
</li>
<li>
<p>Two and three quarters</p>
</li>
</ol>
</li>
<li>
<p>Three</p>
</li>
<li>
<p>Four</p>
</li>
</ol>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Nested ordered list with mixed spacing</h3>
<div class="description">
<p class="p">Ordered lists at different indents, with some spaces between lines.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">0. One
0. Two r
5. Two and a quarter r
6. Two and a half
9. Two and three quarters
99999. Three
7. Four
</code></pre>
</div>
<div class="markup">
<ol class="ol">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two r</p>
<ol class="ol">
<li class="li">
<p class="p">Two and a quarter r</p>
</li>
<li class="li">
<p class="p">Two and a half</p>
</li>
<li class="li">
<p class="p">Two and three quarters</p>
</li>
</ol>
</li>
<li class="li">
<p class="p">Three</p>
</li>
<li class="li">
<p class="p">Four</p>
</li>
</ol>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ol>
<li>
<p>One</p>
</li>
<li>
<p>Two r</p>
<ol>
<li>
<p>Two and a quarter r</p>
</li>
<li>
<p>Two and a half</p>
</li>
<li>
<p>Two and three quarters</p>
</li>
</ol>
</li>
<li>
<p>Three</p>
</li>
<li>
<p>Four</p>
</li>
</ol>
</code></pre>
</div>
</div>
</div>
<div class="test">
<h2 class="title">Unordered lists</h2>
<div class="description">
<p class="p">Unordered lists are indicated by starting a line with <code class="code">*</code>.</p>
</div>
<div class="case">
<h3 class="title">Unordered list with spaces</h3>
<div class="description">
<p class="p">A list with spaces between the lines.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">* One
* Two t
* Three
</code></pre>
</div>
<div class="markup">
<ul class="ul">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two t</p>
</li>
<li class="li">
<p class="p">Three</p>
</li>
</ul>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ul>
<li>
<p>One</p>
</li>
<li>
<p>Two t</p>
</li>
<li>
<p>Three</p>
</li>
</ul>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Unordered list no spaces</h3>
<div class="description">
<p class="p">A list with no spaces between the lines.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">* One
* Two y
* Three
</code></pre>
</div>
<div class="markup">
<ul class="ul">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two y</p>
</li>
<li class="li">
<p class="p">Three</p>
</li>
</ul>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ul>
<li>
<p>One</p>
</li>
<li>
<p>Two y</p>
</li>
<li>
<p>Three</p>
</li>
</ul>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Unordered list mixed spacing</h3>
<div class="description">
<p class="p">A list with mixed spacing between the lines.</p>
</div>
<div class="source">
<pre class="codeblock" data-language="sam"><code class="codeblock" data-language="sam">* One
* Two u
* Three
* Four
</code></pre>
</div>
<div class="markup">
<ul class="ul">
<li class="li">
<p class="p">One</p>
</li>
<li class="li">
<p class="p">Two u</p>
</li>
<li class="li">
<p class="p">Three</p>
</li>
<li class="li">
<p class="p">Four</p>
</li>
</ul>
</div>
<div class="result">
<pre class="codeblock" data-language="xml"><code class="codeblock" data-language="xml"><ul>
<li>
<p>One</p>
</li>
<li>
<p>Two u</p>
</li>
<li>
<p>Three</p>
</li>
<li>
<p>Four</p>
</li>
</ul>
</code></pre>
</div>
</div>
<div class="case">
<h3 class="title">Nested list with spaces</h3>
<div class="description">
<p class="p">Nested lists separated by spaces.</p>