aboutsummaryrefslogtreecommitdiffstats
path: root/tests/extensions
diff options
context:
space:
mode:
authorWaylan Limberg <waylan@gmail.com>2012-01-24 07:57:58 -0500
committerWaylan Limberg <waylan@gmail.com>2012-01-24 07:57:58 -0500
commita9cd895467b3caa08d585458fdcbcc5525356493 (patch)
tree2d99fb25c551217a6e59698f193b649ebdca65b8 /tests/extensions
parentacd09498fbd2b13e65038c96a118fd859a6df235 (diff)
downloadmarkdown-a9cd895467b3caa08d585458fdcbcc5525356493.tar.gz
markdown-a9cd895467b3caa08d585458fdcbcc5525356493.tar.bz2
markdown-a9cd895467b3caa08d585458fdcbcc5525356493.zip
Fixes #64. Added sane_list extension.
This is an extension which alters the behavior of lists to be less surprising. If turned out to be rather simple to code. I'm surprised no one had written it yet. I should note that this extension does not generate separate lists if different unordered list markers are used (`*` verses `-` verses `+`) The way the parser works that would be a little more tricky.
Diffstat (limited to 'tests/extensions')
-rw-r--r--tests/extensions/sane_lists.html21
-rw-r--r--tests/extensions/sane_lists.txt16
-rw-r--r--tests/extensions/test.cfg3
3 files changed, 40 insertions, 0 deletions
diff --git a/tests/extensions/sane_lists.html b/tests/extensions/sane_lists.html
new file mode 100644
index 0000000..b9fe007
--- /dev/null
+++ b/tests/extensions/sane_lists.html
@@ -0,0 +1,21 @@
+<ol>
+<li>Ordered</li>
+<li>List</li>
+</ol>
+<ul>
+<li>Unordered</li>
+<li>List</li>
+</ul>
+<ol>
+<li>Ordered again</li>
+</ol>
+<p>Paragraph
+* not a list item</p>
+<ol>
+<li>More ordered
+* not a list item</li>
+</ol>
+<ul>
+<li>Unordered again
+1. not a list item</li>
+</ul> \ No newline at end of file
diff --git a/tests/extensions/sane_lists.txt b/tests/extensions/sane_lists.txt
new file mode 100644
index 0000000..51981b3
--- /dev/null
+++ b/tests/extensions/sane_lists.txt
@@ -0,0 +1,16 @@
+1. Ordered
+2. List
+
+* Unordered
+* List
+
+1. Ordered again
+
+Paragraph
+* not a list item
+
+1. More ordered
+* not a list item
+
+* Unordered again
+1. not a list item
diff --git a/tests/extensions/test.cfg b/tests/extensions/test.cfg
index 19721ce..ac8a747 100644
--- a/tests/extensions/test.cfg
+++ b/tests/extensions/test.cfg
@@ -26,3 +26,6 @@ extensions=fenced_code
[github_flavored]
extensions=fenced_code
+
+[sane_lists]
+extensions=sane_lists