maruku 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (108) hide show
  1. data/bin/{maruku0.3 → marudown} +6 -14
  2. data/bin/maruku +1 -1
  3. data/bin/marutest +37 -9
  4. data/docs/TOFIX.html +22 -0
  5. data/docs/TOFIX.md +3 -0
  6. data/docs/changelog-0.2.13.html +30 -0
  7. data/docs/changelog-0.2.13.md +6 -0
  8. data/docs/changelog-0.3.html +19 -5
  9. data/docs/faq.html +51 -40
  10. data/docs/faq.md +3 -3
  11. data/docs/hidden_o_n_squared.md +10 -0
  12. data/docs/index.html +84 -396
  13. data/docs/markdown_syntax.html +139 -330
  14. data/docs/markdown_syntax.md +80 -93
  15. data/docs/maruku.html +84 -396
  16. data/docs/maruku.md +88 -158
  17. data/docs/proposal.html +13 -106
  18. data/docs/proposal.md +3 -3
  19. data/docs/todo.html +38 -28
  20. data/lib/maruku.rb +77 -11
  21. data/lib/maruku/attributes.rb +186 -0
  22. data/lib/maruku/defaults.rb +40 -0
  23. data/lib/maruku/errors_management.rb +55 -39
  24. data/lib/maruku/helpers.rb +156 -72
  25. data/lib/maruku/input/charsource.rb +319 -0
  26. data/lib/maruku/{html_helper.rb → input/html_helper.rb} +30 -9
  27. data/lib/maruku/input/linesource.rb +111 -0
  28. data/lib/maruku/input/parse_block.rb +562 -0
  29. data/lib/maruku/{parse_doc.rb → input/parse_doc.rb} +60 -28
  30. data/lib/maruku/{parse_span_better.rb → input/parse_span_better.rb} +226 -256
  31. data/lib/maruku/input/type_detection.rb +137 -0
  32. data/lib/maruku/maruku.rb +33 -0
  33. data/lib/maruku/{to_html.rb → output/to_html.rb} +151 -132
  34. data/lib/maruku/{to_latex.rb → output/to_latex.rb} +31 -35
  35. data/lib/maruku/{to_latex_entities.rb → output/to_latex_entities.rb} +25 -3
  36. data/lib/maruku/output/to_latex_strings.rb +64 -0
  37. data/lib/maruku/output/to_markdown.rb +164 -0
  38. data/lib/maruku/{to_s.rb → output/to_s.rb} +6 -0
  39. data/lib/maruku/string_utils.rb +12 -181
  40. data/lib/maruku/structures.rb +91 -67
  41. data/lib/maruku/structures_inspect.rb +78 -0
  42. data/lib/maruku/structures_iterators.rb +24 -2
  43. data/lib/maruku/tests/benchmark.rb +41 -9
  44. data/lib/maruku/tests/new_parser.rb +317 -286
  45. data/lib/maruku/tests/tests.rb +20 -0
  46. data/lib/maruku/toc.rb +64 -64
  47. data/lib/maruku/usage/example1.rb +33 -0
  48. data/lib/maruku/version.rb +8 -2
  49. data/tests/unittest/abbreviations.md +27 -16
  50. data/tests/unittest/attributes/attributes.md +89 -0
  51. data/tests/unittest/attributes/circular.md +51 -0
  52. data/tests/unittest/attributes/default.md +47 -0
  53. data/tests/unittest/blank.md +10 -6
  54. data/tests/unittest/blanks_in_code.md +26 -26
  55. data/tests/unittest/code.md +9 -9
  56. data/tests/unittest/code2.md +12 -13
  57. data/tests/unittest/code3.md +34 -34
  58. data/tests/unittest/easy.md +9 -7
  59. data/tests/unittest/email.md +9 -7
  60. data/tests/unittest/encoding/iso-8859-1.md +41 -4
  61. data/tests/unittest/encoding/utf-8.md +6 -5
  62. data/tests/unittest/entities.md +52 -80
  63. data/tests/unittest/escaping.md +47 -35
  64. data/tests/unittest/extra_dl.md +19 -29
  65. data/tests/unittest/extra_header_id.md +31 -24
  66. data/tests/unittest/extra_table1.md +14 -32
  67. data/tests/unittest/footnotes.md +58 -42
  68. data/tests/unittest/headers.md +11 -11
  69. data/tests/unittest/hrule.md +14 -24
  70. data/tests/unittest/images.md +41 -26
  71. data/tests/unittest/inline_html.md +104 -56
  72. data/tests/unittest/inline_html2.md +38 -0
  73. data/tests/unittest/links.md +74 -33
  74. data/tests/unittest/list1.md +18 -15
  75. data/tests/unittest/list2.md +31 -13
  76. data/tests/unittest/list3.md +29 -28
  77. data/tests/unittest/list4.md +103 -12
  78. data/tests/unittest/lists.md +86 -53
  79. data/tests/unittest/lists6.md +53 -0
  80. data/tests/unittest/lists7.md +31 -0
  81. data/tests/unittest/lists_after_paragraph.md +105 -71
  82. data/tests/unittest/lists_ol.md +149 -73
  83. data/tests/unittest/misc_sw.md +366 -326
  84. data/tests/unittest/notyet/escape.md +10 -10
  85. data/tests/unittest/notyet/header_after_par.md +20 -14
  86. data/tests/unittest/notyet/ticks.md +8 -35
  87. data/tests/unittest/notyet/triggering.md +72 -45
  88. data/tests/unittest/olist.md +78 -0
  89. data/tests/unittest/one.md +5 -3
  90. data/tests/unittest/paragraph.md +5 -3
  91. data/tests/unittest/paragraph_rules/dont_merge_ref.md +15 -9
  92. data/tests/unittest/paragraph_rules/tab_is_blank.md +9 -5
  93. data/tests/unittest/paragraphs.md +21 -26
  94. data/tests/unittest/recover/recover_links.md +6 -5
  95. data/tests/unittest/references/long_example.md +39 -30
  96. data/tests/unittest/references/spaces_and_numbers.md +2 -2
  97. data/tests/unittest/syntax_hl.md +33 -31
  98. data/tests/unittest/test.md +4 -6
  99. data/tests/unittest/wrapping.md +43 -26
  100. metadata +160 -139
  101. data/docs/markdown_extra2.html +0 -87
  102. data/docs/markdown_extra2.md +0 -83
  103. data/docs/markdown_syntax_2.html +0 -152
  104. data/lib/maruku/parse_block.rb +0 -564
  105. data/lib/maruku/parse_span.rb +0 -451
  106. data/lib/maruku/to_latex_strings.rb +0 -59
  107. data/lib/maruku/to_markdown.rb +0 -110
  108. data/lib/test.rb +0 -29
@@ -0,0 +1,38 @@
1
+
2
+ *** Parameters: ***
3
+ {}
4
+ *** Markdown input: ***
5
+ <div markdown="1">Test **bold**</div>
6
+ <p markdown="1">Test **bold**</p>
7
+ *** Output of inspect ***
8
+ md_el(:document,[
9
+ md_html("<div markdown=\"1\">Test **bold**</div>"),
10
+ md_html("<p markdown=\"1\">Test **bold**</p>")
11
+ ],{},[])
12
+ *** Output of to_html ***
13
+ <div>
14
+ <p>Test <strong>bold</strong></p>
15
+ </div><p>Test <strong>bold</strong></p>
16
+ *** Output of to_latex ***
17
+ {\bf Raw HTML removed in latex version }{\bf Raw HTML removed in latex version }
18
+ *** Output of to_md ***
19
+
20
+ *** Output of to_s ***
21
+
22
+ *** EOF ***
23
+
24
+
25
+
26
+ OK!
27
+
28
+
29
+
30
+ *** Output of Markdown.pl ***
31
+ <div markdown="1">Test **bold**</div>
32
+
33
+ <p markdown="1">Test **bold**</p>
34
+
35
+ *** Output of Markdown.pl (parsed) ***
36
+ <div markdown='1'>Test **bold**</div
37
+ ><p markdown='1'>Test **bold**</p
38
+ >
@@ -41,39 +41,39 @@ If all else fails, ask [Google](http://www.google.com)
41
41
  *** Output of inspect ***
42
42
  md_el(:document,[
43
43
  md_par(["Search on ", md_link(["Google"],"")]),
44
- md_par(["Search on ", md_link(["Google"],"")]),
45
- md_par(["Search on ", md_link(["Google"],"google")]),
46
- md_par(["Search on ", md_link(["Google"],"google")]),
47
- md_par(["Search on ", md_link(["Google images"],"")]),
48
- md_par(["Inline: ", md_im_link(["Google images"], "http://google.com" )]),
49
- md_par([
44
+ md_par(["Search on ", md_link(["Google"],"")]),
45
+ md_par(["Search on ", md_link(["Google"],"google")]),
46
+ md_par(["Search on ", md_link(["Google"],"google")]),
47
+ md_par(["Search on ", md_link(["Google images"],"")]),
48
+ md_par(["Inline: ", md_im_link(["Google images"], "http://google.com", nil)]),
49
+ md_par([
50
50
  "Inline with title: ",
51
- md_im_link(["Google images"], "http://google.com" , "Title")
51
+ md_im_link(["Google images"], "http://google.com", "Title")
52
52
  ]),
53
- md_par([
53
+ md_par([
54
54
  "Inline with title: ",
55
- md_im_link(["Google images"], "http://google.com" , "Title")
55
+ md_im_link(["Google images"], "http://google.com", "Title")
56
56
  ]),
57
- md_par([
57
+ md_par([
58
58
  "Search on ",
59
- md_url("http://www.gogole.com"),
60
- " or ",
61
- md_url("http://Here.com"),
62
- " or ask ",
63
- md_email("bill@google.com"),
64
- " or you might ask bill@google.com."
59
+ md_url("http://www.gogole.com"),
60
+ " or ",
61
+ md_url("http://Here.com"),
62
+ " or ask ",
63
+ md_email("bill@google.com"),
64
+ " or you might ask bill@google.com."
65
65
  ]),
66
- md_par([
66
+ md_par([
67
67
  "If all else fails, ask ",
68
- md_im_link(["Google"], "http://www.google.com" )
68
+ md_im_link(["Google"], "http://www.google.com", nil)
69
69
  ]),
70
- md_ref_def("google", "http://www.google.com" ,{:title=>nil}),
71
- md_ref_def("google2", "http://www.google.com" ,{:title=>"Single quotes"}),
72
- md_ref_def("google3", "http://www.google.com" ,{:title=>"Double quotes"}),
73
- md_ref_def("google4", "http://www.google.com" ,{:title=>"Parenthesis"}),
74
- md_ref_def("google search", "http://www.google.com" ,{:title=>"Google search"}),
75
- md_ref_def("google images", "http://images.google.com" ,{:title=>"Google images"})
76
- ] , {:on_error=>:warning})
70
+ md_ref_def("google", "http://www.google.com", {:title=>nil}),
71
+ md_ref_def("google2", "http://www.google.com", {:title=>"Single quotes"}),
72
+ md_ref_def("google3", "http://www.google.com", {:title=>"Double quotes"}),
73
+ md_ref_def("google4", "http://www.google.com", {:title=>"Parenthesis"}),
74
+ md_ref_def("google search", "http://www.google.com", {:title=>"Google search"}),
75
+ md_ref_def("google images", "http://images.google.com", {:title=>"Google images"})
76
+ ],{},[])
77
77
  *** Output of to_html ***
78
78
 
79
79
  <p>Search on <a href='http://www.google.com'>Google</a></p>
@@ -107,19 +107,40 @@ Search on \href{http://www.google.com}{Google}
107
107
 
108
108
  Search on \href{http://images.google.com}{Google images}
109
109
 
110
- Inline: \href{http://google.com}{Google images}
110
+ Inline:
111
111
 
112
- Inline with title: \href{http://google.com}{Google images}
112
+ Inline with title:
113
113
 
114
- Inline with title: \href{http://google.com}{Google images}
114
+ Inline with title:
115
115
 
116
116
  Search on \href{http://www.gogole.com}{http://www.gogole.com} or \href{http://Here.com}{http://Here.com} or ask \href{mailto:bill@google.com}{\char98\char105\char108\char108\char64\char103\char111\char111\char103\char108\char101\char46\char99\char111\char109} or you might ask bill@google.com.
117
117
 
118
- If all else fails, ask \href{http://www.google.com}{Google}
118
+ If all else fails, ask
119
+
120
+
121
+ *** Output of to_md ***
122
+ Search on Google
123
+
124
+ Search on Google
125
+
126
+ Search on Google
127
+
128
+ Search on Google
129
+
130
+ Search on Google images
131
+
132
+ Inline: Google images
133
+
134
+ Inline with title: Google images
135
+
136
+ Inline with title: Google images
137
+
138
+ Search on or or ask or you might ask
139
+ bill@google.com.
140
+
141
+ If all else fails, ask Google
119
142
 
120
143
 
121
- *** Output of to_s ***
122
- Search on GoogleSearch on GoogleSearch on GoogleSearch on GoogleSearch on Google imagesInline: Google imagesInline with title: Google imagesInline with title: Google imagesSearch on or or ask or you might ask bill@google.com.If all else fails, ask Google
123
144
  *** Output of to_s ***
124
145
  Search on GoogleSearch on GoogleSearch on GoogleSearch on GoogleSearch on Google imagesInline: Google imagesInline with title: Google imagesInline with title: Google imagesSearch on or or ask or you might ask bill@google.com.If all else fails, ask Google
125
146
  *** EOF ***
@@ -147,7 +168,7 @@ Search on GoogleSearch on GoogleSearch on GoogleSearch on GoogleSearch on Google
147
168
 
148
169
  <p>Inline with title: <a href="http://google.com "Title"">Google images</a></p>
149
170
 
150
- <p>Search on <a href="http://www.gogole.com">http://www.gogole.com</a> or <a href="http://Here.com">http://Here.com</a> or ask <a href="&#x6D;&#x61;&#105;&#108;t&#111;:&#x62;&#x69;&#108;&#x6C;&#64;&#x67;&#111;og&#108;&#101;&#46;&#x63;&#111;m">&#x62;&#x69;&#108;&#x6C;&#64;&#x67;&#111;og&#108;&#101;&#46;&#x63;&#111;m</a>
171
+ <p>Search on <a href="http://www.gogole.com">http://www.gogole.com</a> or <a href="http://Here.com">http://Here.com</a> or ask <a href="&#109;&#x61;&#105;&#x6C;&#x74;o:&#98;&#x69;&#108;l&#64;&#x67;&#111;&#x6F;&#103;&#x6C;&#101;&#46;&#x63;&#111;m">&#98;&#x69;&#108;l&#64;&#x67;&#111;&#x6F;&#103;&#x6C;&#101;&#46;&#x63;&#111;m</a>
151
172
  or you might ask bill@google.com.</p>
152
173
 
153
174
  <p>If all else fails, ask <a href="http://www.google.com">Google</a></p>
@@ -155,7 +176,27 @@ or you might ask bill@google.com.</p>
155
176
  <p>[google2]: http://www.google.com 'Single quotes'</p>
156
177
 
157
178
  *** Output of Markdown.pl (parsed) ***
158
- Error: #<REXML::ParseException: Missing end tag for 'p' (got "div")
179
+ Error: #<REXML::ParseException: #<REXML::ParseException: Missing end tag for 'p' (got "div")
180
+ Line:
181
+ Position:
182
+ Last 80 unconsumed characters:
183
+ >
184
+ /Volumes/Alter/Ruby/local/lib/ruby/1.8/rexml/parsers/baseparser.rb:315:in `pull'
185
+ /Volumes/Alter/Ruby/local/lib/ruby/1.8/rexml/parsers/treeparser.rb:21:in `parse'
186
+ /Volumes/Alter/Ruby/local/lib/ruby/1.8/rexml/document.rb:190:in `build'
187
+ /Volumes/Alter/Ruby/local/lib/ruby/1.8/rexml/document.rb:45:in `initialize'
188
+ bin/marutest:171:in `new'
189
+ bin/marutest:171:in `run_test'
190
+ bin/marutest:235:in `marutest'
191
+ bin/marutest:233:in `each'
192
+ bin/marutest:233:in `marutest'
193
+ bin/marutest:303
194
+ ...
195
+ Missing end tag for 'p' (got "div")
196
+ Line:
197
+ Position:
198
+ Last 80 unconsumed characters:
199
+
159
200
  Line:
160
201
  Position:
161
202
  Last 80 unconsumed characters:
@@ -12,10 +12,10 @@ md_el(:document,[
12
12
  md_el(:ul,[
13
13
  md_el(:li,[
14
14
  md_par(["A list item with a blockquote:"]),
15
- md_el(:quote,[md_par(["This is a blockquote inside a list item."])] )
16
- ] , {:want_my_paragraph=>true})
17
- ] )
18
- ] )
15
+ md_el(:quote,[md_par(["This is a blockquote inside a list item."])],{},[])
16
+ ],{:want_my_paragraph=>true},[])
17
+ ],{},[])
18
+ ],{},[])
19
19
  *** Output of to_html ***
20
20
 
21
21
  <ul>
@@ -41,8 +41,12 @@ This is a blockquote inside a list item.
41
41
 
42
42
  \end{itemize}
43
43
 
44
- *** Output of to_s ***
45
- A list item with a blockquote:This is a blockquote inside a list item.
44
+ *** Output of to_md ***
45
+ - list item with a blockquote:
46
+ This is a blockquote inside a list
47
+ item.
48
+
49
+
46
50
  *** Output of to_s ***
47
51
  A list item with a blockquote:This is a blockquote inside a list item.
48
52
  *** EOF ***
@@ -66,15 +70,14 @@ A list item with a blockquote:This is a blockquote inside a list item.
66
70
  *** Output of Markdown.pl (parsed) ***
67
71
  <ul>
68
72
  <li
69
- ><p>A list item with a blockquote:</p
70
- >
71
-
73
+ ><p>A list item with a blockquote:</p
74
+ >
72
75
  <blockquote>
73
- <p>This is a blockquote
74
- inside a list item.</p
75
- >
76
+ <p>This is a blockquote
77
+ inside a list item.</p
78
+ >
76
79
  </blockquote
77
- ></li
78
- >
80
+ ></li
81
+ >
79
82
  </ul
80
- >
83
+ >
@@ -8,17 +8,20 @@ Write a comment abouth the test here.
8
8
  only required to indent the first line. Lorem ipsum dolor
9
9
  sit amet, consectetuer adipiscing elit.
10
10
 
11
+ * other
12
+
11
13
  *** Output of inspect ***
12
14
  md_el(:document,[
13
15
  md_el(:ul,[
14
16
  md_el(:li,[
15
17
  md_par(["This is a list item with two paragraphs."]),
16
- md_par([
18
+ md_par([
17
19
  "This is the second paragraph in the list item. You're only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elit"
18
20
  ])
19
- ] , {:want_my_paragraph=>true})
20
- ] )
21
- ] )
21
+ ],{:want_my_paragraph=>true},[]),
22
+ md_el(:li,[md_par(["other"])],{:want_my_paragraph=>false},[])
23
+ ],{},[])
24
+ ],{},[])
22
25
  *** Output of to_html ***
23
26
 
24
27
  <ul>
@@ -27,6 +30,10 @@ md_el(:document,[
27
30
 
28
31
  <p>This is the second paragraph in the list item. You&apos;re only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elit</p>
29
32
  </li>
33
+
34
+ <li>
35
+ <p>other</p>
36
+ </li>
30
37
  </ul>
31
38
 
32
39
  *** Output of to_latex ***
@@ -36,13 +43,20 @@ md_el(:document,[
36
43
  This is the second paragraph in the list item. You're only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elit
37
44
 
38
45
 
46
+ \item other
47
+
48
+
39
49
 
40
50
  \end{itemize}
41
51
 
52
+ *** Output of to_md ***
53
+ -This is a list item with two paragraphs.
54
+ This is the second paragraph in the list item. You're only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elit
55
+ -ther
56
+
57
+
42
58
  *** Output of to_s ***
43
- This is a list item with two paragraphs.This is the second paragraph in the list item. You're only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elit
44
- *** Output of to_s ***
45
- This is a list item with two paragraphs.This is the second paragraph in the list item. You're only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elit
59
+ This is a list item with two paragraphs.This is the second paragraph in the list item. You're only required to indent the first line. Lorem ipsum dolo sit amet, consectetuer adipiscing elitother
46
60
  *** EOF ***
47
61
 
48
62
 
@@ -58,18 +72,22 @@ This is a list item with two paragraphs.This is the second paragraph in the list
58
72
  <p>This is the second paragraph in the list item. You're
59
73
  only required to indent the first line. Lorem ipsum dolor
60
74
  sit amet, consectetuer adipiscing elit.</p></li>
75
+ <li><p>other</p></li>
61
76
  </ul>
62
77
 
63
78
  *** Output of Markdown.pl (parsed) ***
64
79
  <ul>
65
80
  <li
66
- ><p>This is a list item with two paragraphs.</p
67
- >
68
-
81
+ ><p>This is a list item with two paragraphs.</p
82
+ >
69
83
  <p>This is the second paragraph in the list item. You're
70
84
  only required to indent the first line. Lorem ipsum dolor
71
85
  sit amet, consectetuer adipiscing elit.</p
72
- ></li
73
- >
86
+ ></li
87
+ >
88
+ <li
89
+ ><p>other</p
90
+ ></li
91
+ >
74
92
  </ul
75
- >
93
+ >
@@ -15,14 +15,14 @@ md_el(:document,[
15
15
  md_el(:ul,[
16
16
  md_el(:li,[
17
17
  md_par(["A list item with a blockquote:"]),
18
- md_el(:quote,[md_par(["This is a blockquote inside a list item."])] )
19
- ] , {:want_my_paragraph=>true}),
20
- md_el(:li,[
18
+ md_el(:quote,[md_par(["This is a blockquote inside a list item."])],{},[])
19
+ ],{:want_my_paragraph=>true},[]),
20
+ md_el(:li,[
21
21
  md_par(["A list item with a code block:"]),
22
- md_el(:code,[] , {:raw_code=>"<code goes here>"})
23
- ] , {:want_my_paragraph=>true})
24
- ] )
25
- ] )
22
+ md_el(:code,[],{:raw_code=>"<code goes here>"},[])
23
+ ],{:want_my_paragraph=>true},[])
24
+ ],{},[])
25
+ ],{},[])
26
26
  *** Output of to_html ***
27
27
 
28
28
  <ul>
@@ -36,9 +36,7 @@ md_el(:document,[
36
36
 
37
37
  <li>
38
38
  <p>A list item with a code block:</p>
39
-
40
- <pre><code>&lt;code goes here&gt;</code></pre>
41
- </li>
39
+ <pre><code>&lt;code goes here&gt;</code></pre></li>
42
40
  </ul>
43
41
 
44
42
  *** Output of to_latex ***
@@ -58,8 +56,13 @@ This is a blockquote inside a list item.
58
56
 
59
57
  \end{itemize}
60
58
 
61
- *** Output of to_s ***
62
- A list item with a blockquote:This is a blockquote inside a list item.A list item with a code block:
59
+ *** Output of to_md ***
60
+ - list item with a blockquote:
61
+ This is a blockquote inside a list
62
+ item.
63
+ - list item with a code block:
64
+
65
+
63
66
  *** Output of to_s ***
64
67
  A list item with a blockquote:This is a blockquote inside a list item.A list item with a code block:
65
68
  *** EOF ***
@@ -87,25 +90,23 @@ A list item with a blockquote:This is a blockquote inside a list item.A list ite
87
90
  *** Output of Markdown.pl (parsed) ***
88
91
  <ul>
89
92
  <li
90
- ><p>A list item with a blockquote:</p
91
- >
92
-
93
+ ><p>A list item with a blockquote:</p
94
+ >
93
95
  <blockquote>
94
- <p>This is a blockquote
95
- inside a list item.</p
96
- >
96
+ <p>This is a blockquote
97
+ inside a list item.</p
98
+ >
97
99
  </blockquote
98
- ></li
99
- >
100
+ ></li
101
+ >
100
102
  <li
101
- ><p>A list item with a code block:</p
102
- >
103
-
103
+ ><p>A list item with a code block:</p
104
+ >
104
105
  <pre
105
- ><code>&lt;code goes here&gt;
106
+ ><code>&lt;code goes here&gt;
106
107
  </code
107
- ></pre
108
- ></li
109
- >
108
+ ></pre
109
+ ></li
110
+ >
110
111
  </ul
111
- >
112
+ >
@@ -5,22 +5,94 @@ Write a comment abouth the test here.
5
5
  This is a list:
6
6
  * one
7
7
  * two
8
- * three
8
+
9
+ This is not a list:
10
+ * one
11
+ ciao
12
+
13
+ This is a list:
14
+ 1. one
15
+ 1. two
16
+
17
+ This is not a list:
18
+ 1987. one
19
+ ciao
9
20
 
10
21
  *** Output of inspect ***
11
- md_el(:document,[md_par(["This is a list: * one * two * three"])] )
22
+ md_el(:document,[
23
+ md_par(["This is a list:"]),
24
+ md_el(:ul,[
25
+ md_el(:li_span,["one"],{:want_my_paragraph=>false},[]),
26
+ md_el(:li_span,["two"],{:want_my_paragraph=>false},[])
27
+ ],{},[]),
28
+ md_par(["This is not a list: * one ciao"]),
29
+ md_par(["This is a list:"]),
30
+ md_el(:ol,[
31
+ md_el(:li_span,["one"],{:want_my_paragraph=>false},[]),
32
+ md_el(:li_span,["two"],{:want_my_paragraph=>false},[])
33
+ ],{},[]),
34
+ md_par(["This is not a list: 1987. one ciao"])
35
+ ],{},[])
12
36
  *** Output of to_html ***
13
37
 
14
- <p>This is a list: * one * two * three</p>
38
+ <p>This is a list:</p>
39
+
40
+ <ul>
41
+ <li>one</li>
42
+
43
+ <li>two</li>
44
+ </ul>
45
+
46
+ <p>This is not a list: * one ciao</p>
47
+
48
+ <p>This is a list:</p>
49
+
50
+ <ol>
51
+ <li>one</li>
52
+
53
+ <li>two</li>
54
+ </ol>
55
+
56
+ <p>This is not a list: 1987. one ciao</p>
15
57
 
16
58
  *** Output of to_latex ***
17
- This is a list: * one * two * three
59
+ This is a list:
60
+
61
+ \begin{itemize}%
62
+ \item one
63
+ \item two
64
+
65
+ \end{itemize}
66
+ This is not a list: * one ciao
67
+
68
+ This is a list:
69
+
70
+ \begin{enumerate}%
71
+ \item one
72
+ \item two
73
+
74
+ \end{enumerate}
75
+ This is not a list: 1987. one ciao
76
+
77
+
78
+ *** Output of to_md ***
79
+ This is a list:
80
+
81
+ -ne
82
+ -wo
83
+
84
+ This is not a list: * one ciao
85
+
86
+ This is a list:
87
+
88
+ 1. one
89
+ 2. two
90
+
91
+ This is not a list: 1987. one ciao
18
92
 
19
93
 
20
94
  *** Output of to_s ***
21
- This is a list: * one * two * three
22
- *** Output of to_s ***
23
- This is a list: * one * two * three
95
+ This is a list:onetwoThis is not a list: * one ciaoThis is a list:onetwoThis is not a list: 1987. one ciao
24
96
  *** EOF ***
25
97
 
26
98
 
@@ -32,12 +104,31 @@ This is a list: * one * two * three
32
104
  *** Output of Markdown.pl ***
33
105
  <p>This is a list:
34
106
  * one
35
- * two
36
- * three</p>
107
+ * two</p>
108
+
109
+ <p>This is not a list:
110
+ * one
111
+ ciao</p>
112
+
113
+ <p>This is a list:
114
+ 1. one
115
+ 1. two</p>
116
+
117
+ <p>This is not a list:
118
+ 1987. one
119
+ ciao</p>
37
120
 
38
121
  *** Output of Markdown.pl (parsed) ***
39
122
  <p>This is a list:
40
123
  * one
41
- * two
42
- * three</p
43
- >
124
+ * two</p
125
+ ><p>This is not a list:
126
+ * one
127
+ ciao</p
128
+ ><p>This is a list:
129
+ 1. one
130
+ 1. two</p
131
+ ><p>This is not a list:
132
+ 1987. one
133
+ ciao</p
134
+ >