diff options
author | Waylan Limberg <waylan@gmail.com> | 2008-08-22 17:37:37 -0400 |
---|---|---|
committer | Waylan Limberg <waylan@gmail.com> | 2008-08-22 17:37:37 -0400 |
commit | a5cc42b5e441af8f34a122624d136cfcb772c65e (patch) | |
tree | abbced77929e33dccdfce878354d9ba379c24bb1 /tests/misc | |
parent | 0efd44b8e22a43a9df167a2c88aa92d3723dabae (diff) | |
download | markdown-a5cc42b5e441af8f34a122624d136cfcb772c65e.tar.gz markdown-a5cc42b5e441af8f34a122624d136cfcb772c65e.tar.bz2 markdown-a5cc42b5e441af8f34a122624d136cfcb772c65e.zip |
Fixed Ticket 13. Raw block-level html are no longer being inserted into <p> tags.
Also edited numerious tests that were expecting wrong output - they now expect
correct output. Note that a few **still fail** because the output before moving
to ELementTree wasn't correct either. So I set the expected output to what I
think it should be so we don't forget about it later.
I should also note that the 'safe-mode' tests are failing. However, I believe
the current expected output is correct as it is valid html. Interestingly,
these tests passed prior to this fix. We'll need to special case safe-mode here.
Diffstat (limited to 'tests/misc')
-rw-r--r-- | tests/misc/CRLF_line_ends.html | 4 | ||||
-rw-r--r-- | tests/misc/comments.html | 5 | ||||
-rw-r--r-- | tests/misc/div.html | 7 | ||||
-rw-r--r-- | tests/misc/hash.html | 10 | ||||
-rw-r--r-- | tests/misc/mismatched-tags.html | 6 | ||||
-rw-r--r-- | tests/misc/more_comments.html | 6 | ||||
-rw-r--r-- | tests/misc/multi-line-tags.html | 5 | ||||
-rw-r--r-- | tests/misc/multiline-comments.html | 15 | ||||
-rw-r--r-- | tests/misc/php.html | 13 | ||||
-rw-r--r-- | tests/misc/pre.html | 9 | ||||
-rw-r--r-- | tests/misc/span.html | 8 |
11 files changed, 49 insertions, 39 deletions
diff --git a/tests/misc/CRLF_line_ends.html b/tests/misc/CRLF_line_ends.html index c650e58..a72b1ca 100644 --- a/tests/misc/CRLF_line_ends.html +++ b/tests/misc/CRLF_line_ends.html @@ -1,4 +1,4 @@ <p>foo</p> -<p><div> +<div> bar -</div></p>
\ No newline at end of file +</div>
\ No newline at end of file diff --git a/tests/misc/comments.html b/tests/misc/comments.html index 7a03e53..005a755 100644 --- a/tests/misc/comments.html +++ b/tests/misc/comments.html @@ -1,4 +1,5 @@ <p>X<0</p> <p>X>0</p> -<p><!-- A comment --></p> -<p><div>as if</div></p>
\ No newline at end of file +<!-- A comment --> + +<div>as if</div>
\ No newline at end of file diff --git a/tests/misc/div.html b/tests/misc/div.html index 634136c..acd8eaf 100644 --- a/tests/misc/div.html +++ b/tests/misc/div.html @@ -1,5 +1,6 @@ -<p><div id="sidebar"></p> +<div id="sidebar"> + <p> -<em>foo</em> + <em>foo</em> </p> -<p></div></p>
\ No newline at end of file +</div>
\ No newline at end of file diff --git a/tests/misc/hash.html b/tests/misc/hash.html index 5e8bffb..1865994 100644 --- a/tests/misc/hash.html +++ b/tests/misc/hash.html @@ -1,9 +1,11 @@ <p>a</p> -<p><pre> +<pre> #!/usr/bin/python -hello</pre></p> +hello</pre> + <p>a</p> -<p><pre> +<pre> !/usr/bin/python -hello</pre></p> +hello</pre> + <p>a</p>
\ No newline at end of file diff --git a/tests/misc/mismatched-tags.html b/tests/misc/mismatched-tags.html index edeba33..792a8b9 100644 --- a/tests/misc/mismatched-tags.html +++ b/tests/misc/mismatched-tags.html @@ -1,5 +1,3 @@ -<p><p>Some text</p><div>some more text</div> +<p>Some text</p><div>some more text</div> -and a bit more - -</p>
\ No newline at end of file +<p>and a bit more</p> diff --git a/tests/misc/more_comments.html b/tests/misc/more_comments.html index d4430cd..37436c5 100644 --- a/tests/misc/more_comments.html +++ b/tests/misc/more_comments.html @@ -1,9 +1,7 @@ -<p><!--asd@asdfd.com> +<!--asd@asdfd.com> <!asd@asdfd.com> <asd!@asdfd.com> -Test - -</p>
\ No newline at end of file +<p>Test</p> diff --git a/tests/misc/multi-line-tags.html b/tests/misc/multi-line-tags.html index 6d2d97f..763a050 100644 --- a/tests/misc/multi-line-tags.html +++ b/tests/misc/multi-line-tags.html @@ -1,3 +1,4 @@ -<p><div></p> +<div> + <p>asdf asdfasd</p> -<p></div></p>
\ No newline at end of file +</div>
\ No newline at end of file diff --git a/tests/misc/multiline-comments.html b/tests/misc/multiline-comments.html index 429e71b..547ba0b 100644 --- a/tests/misc/multiline-comments.html +++ b/tests/misc/multiline-comments.html @@ -1,13 +1,16 @@ -<p><!-- +<!-- foo ---></p> -<p><p> +--> + +<p> foo -</p></p> -<p><div></p> +</p> + +<div> + <p>foo</p> -<p></div></p>
\ No newline at end of file +</div>
\ No newline at end of file diff --git a/tests/misc/php.html b/tests/misc/php.html index 66bc8d1..6d91404 100644 --- a/tests/misc/php.html +++ b/tests/misc/php.html @@ -1,9 +1,12 @@ -<p><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> -<b>This should have a p tag</b> +<p><b>This should have a p tag</b></p> + +<!--This is a comment --> + +<div>This shouldn't</div> + +<?php echo "block_level";?> -<!--This is a comment --></p> -<p><div>This shouldn't</div></p> -<p><?php echo "block_level";?></p> <p> <?php echo "not_block_level";?></p> diff --git a/tests/misc/pre.html b/tests/misc/pre.html index 5ac9799..a44ae12 100644 --- a/tests/misc/pre.html +++ b/tests/misc/pre.html @@ -1,12 +1,13 @@ -<p><pre> +<pre> aaa bbb -</pre></p> -<p><pre> +</pre> + +<pre> * and this is pre-formatted content * and it should be printed just like this * and not formatted as a list -</pre></p>
\ No newline at end of file +</pre>
\ No newline at end of file diff --git a/tests/misc/span.html b/tests/misc/span.html index dadf5df..bafcf0f 100644 --- a/tests/misc/span.html +++ b/tests/misc/span.html @@ -1,4 +1,6 @@ <p><span id="someId"> Foo <em>bar</em> Baz </span></p> -<p><div><b>*foo*</b></div></p> -<p><div id="someId"> Foo *bar* Baz </div></p> -<p><baza id="someId"> Foo <em>bar</em> Baz </baza></p> +<div><b>*foo*</b></div> + +<div id="someId"> Foo *bar* Baz </div> + +<p><baza id="someId"> Foo <em>bar</em> Baz </baza></p>
\ No newline at end of file |