aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorWaylan Limberg <waylan@gmail.com>2009-06-17 17:14:01 -0400
committerWaylan Limberg <waylan@gmail.com>2009-06-17 17:14:01 -0400
commitc38f1813a1c2d7c531517a74c456166af92356b4 (patch)
tree0a9af9189447fe3cc38c88a2e3a3de8f807aa19f /tests
parent0ae9951f49eb75c8a9fb9f841673b889763c1811 (diff)
downloadmarkdown-c38f1813a1c2d7c531517a74c456166af92356b4.tar.gz
markdown-c38f1813a1c2d7c531517a74c456166af92356b4.tar.bz2
markdown-c38f1813a1c2d7c531517a74c456166af92356b4.zip
Fixed ticket 35. Lists now work when padded with five or more spaces after asterisk. Adjusted regex to eat all (one or more) of the spaces. While it may seem wrong (at least in the loose list case), this is how all other implementations work. And it solves a number of edge cases otherwise not accounted for in the list parser.
Diffstat (limited to 'tests')
-rw-r--r--tests/misc/lists6.html18
-rw-r--r--tests/misc/lists6.txt14
2 files changed, 32 insertions, 0 deletions
diff --git a/tests/misc/lists6.html b/tests/misc/lists6.html
new file mode 100644
index 0000000..24aad38
--- /dev/null
+++ b/tests/misc/lists6.html
@@ -0,0 +1,18 @@
+<p>Test five or more spaces as start of list:</p>
+<ul>
+<li>five spaces</li>
+</ul>
+<p>not first item:</p>
+<ul>
+<li>one space</li>
+<li>five spaces</li>
+</ul>
+<p>loose list:</p>
+<ul>
+<li>
+<p>one space</p>
+</li>
+<li>
+<p>five spaces</p>
+</li>
+</ul> \ No newline at end of file
diff --git a/tests/misc/lists6.txt b/tests/misc/lists6.txt
new file mode 100644
index 0000000..f12788f
--- /dev/null
+++ b/tests/misc/lists6.txt
@@ -0,0 +1,14 @@
+Test five or more spaces as start of list:
+
+* five spaces
+
+not first item:
+
+* one space
+* five spaces
+
+loose list:
+
+* one space
+
+* five spaces