aboutsummaryrefslogtreecommitdiffstats
path: root/tests/misc
Commit message (Collapse)AuthorAgeFilesLines
* No longer percent encode spaces in urls.Waylan Limberg2014-01-091-2/+2
| | | | | | | | | | | The current implementation was wrong as it also percent encoded query strings (which should be plus encoded) and calling urllib.quote on the path (and urllib.quote_plus on the query string) assumes the url is not already encoded. What if the document author pasted a url that was already encoded? She probably did not intend for `%20` to become `%2520`. Or did she? It is now clear to me why many implementation do nothing to urls. Just pass them though as-is. To bad if they are not valid HTML. HTML authors have to encodee their own urls, so I guess markdown authors have to as well.
* Only escape ESCAPED_CHARS.Waylan Limberg2014-01-092-0/+24
| | | | | | Leave all other chars prefaced by a backslash alone. Fixes #242. Not sure why I thought that I needed to add another backslash. Thanks for the report and the test case @mhubig.
* Fixed parsing of brackets within inline image titles.Darell Tan2014-01-052-0/+21
|
* HtmlBlockProcessor preserves empty linesWaylan Limberg2013-02-072-8/+74
| | | | | | | | | | | | | Partial fix for #183. This has the same effect on empty lines in code blocks as not using the html processor at all (which was eating some of the missing newlines as reported in issue #183). By doing `rsplit('\n\n')` the third newline (in each set of three) always ends up at the end of a block, rather than the begining - which it less of an issue for the html processor. Also updated tests to indicate final intended output, although they do not fully pass yet.
* Preserve whitespace in empty linesWaylan Limberg2013-02-072-0/+68
| | | | | | | | Partial fix for #183. By preserving tabs at the start of empty lines in code blocks, the parser will retain those empty lines. Still does not work consistantly if the tab is missing!? Not sure why. Also added tests.
* Enable attributes inside image referencesAdam Backstrom2013-01-272-0/+5
|
* Fixed #153. Two spaces at end of paragraph is not a linebreak.Waylan Limberg2012-10-212-6/+3
|
* Fixed #152. Spaces in links are now escaped.Waylan Limberg2012-10-211-2/+2
|
* Fixed #151. Raw html matching is now case-insensitive.Waylan Limberg2012-10-212-1/+12
|
* Fixed #106. Replaced all references to freewisdom.org (except for Yuri's ↵Waylan Limberg2012-06-284-24/+24
| | | | homepage).
* Add test for 5236a9838c580a17c3299efb97d9f41ce2a1efabCatalin Iacob2012-04-173-0/+7
|
* tests for 9852c2263ef7775d2a508a9c1721148cbf3ae258fin2012-04-112-0/+2
|
* Fixed #68. Blank line is not required after html comments.Waylan Limberg2011-12-293-2/+12
| | | | | Interestingly, the change to the misc/mismatched-tags test is inline with PHP Markdown Extra's behavior but not markdown.pl, which produces invalid html.
* Fixed #57. Multiline HTML Blocks no longer require a blank line after them.Waylan Limberg2011-12-293-2/+17
|
* Fixed #47. Improved HRProccessor.\n\nPython's re module does not support ↵Waylan Limberg2011-11-172-1/+7
| | | | atomic grouping, which was slowing the HR regex down if a long HR ended with a non HR char (casing the regex to backtrack). Therefore, we have to simulate atomic grouping. Fortunately, we only need to match end-of-line or end-of-string after the atomic group here, so it was an easy case to simulate. Just remove the '$' from the end of the regex and manualy check using m.end(). The run method was refactored while I was at it, saving us from running the regex twice for each HR.
* Fixed #31. Headers in tight lists now get inline patterns run on their ↵Waylan Limberg2011-07-212-4/+4
| | | | tails. Tests included.
* Fixed #28. Inline raw html is now enclosed in p tags. This used to work. ↵Waylan Limberg2011-06-283-2/+4
| | | | Somehow we stopped checking for a single inline html element when swapping back in raw html. Added a test. Also patched a weird (invalid) comment test. Seeing the input is not really a valid html comment - it doesn't matter what we do with it. I suppose we test it to make sure it doesn't break the parser. Actual output is not so important. As a side note, this has exposed a preexisting (unrelated) bug with the extra extension's handling of raw html. That test is failing following this fix.
* Added test for escaping chars in link urls. Closes #14 which was fixed in ↵Waylan Limberg2011-06-232-0/+10
| | | | previous commits. This addes the missing tests.
* Added our own xhtml searializer. We no longer use a xml searializer to ↵Waylan Limberg2011-06-162-4/+4
| | | | output xhtml. This fixes #9 among other bugs. The test suite even had bad tests that should have been failing. They also have been corrected.
* Fixed #21. A header and paragraph not seperated by a blank line inside a ↵Waylan Limberg2011-06-152-0/+34
| | | | list item are now parsed correctly. One of those crazy wierd edge cases that no one would ever test for, but is obvious once you see it.
* Fixed #19. Improved Start Emphasis regex.Waylan Limberg2011-06-072-1/+3
|
* Fixed #15. Setext Headers now work with any number of - or = characters.Waylan Limberg2011-06-012-1/+9
|
* Added new HTML5 block elements to known block level elementsHorst Gutmann2011-05-222-0/+30
|
* Made lazy ordered lists a settable option. The previous behavior (on) is the ↵Waylan Limberg2011-04-291-2/+2
| | | | default.
* fixed startindex reset in multiple ulRohan Jain2011-04-051-2/+2
| | | | | Now the startindex would be reset if continual unordered lists are present (tests are passed).
* Added test files for bug fix to ticket 62Gerry LaMontagne2010-09-024-0/+70
|
* Fixed Ticket 65. Lines with only a lessthan sign (<) no longer crash the ↵Waylan Limberg2010-07-142-1/+14
| | | | raw html parser. Fixed a related but I found while debugging this as well. Also added tests for both.
* Blockquoted text in the first item of a list is now placed in child p tag of theGerry LaMontagne2010-03-232-0/+55
| | | | blockquote tag. Added lists8.txt and .html for test suite to test condition.
* Fixed ticket 58. The first item of a looselist gets placed in p tags whenGerry LaMontagne2010-03-221-2/+4
| | | | | | it has a sublist. Previously, the test suite erroneously passed this condition because there was an error in the expected '.html' output file. The expected output has been corrected as well.
* Fixed Ticket 57. Lists where the first line of an item is a nested item, now ↵Waylan Limberg2010-03-192-0/+142
| | | | observe rules for using p tags. Thanks to Gerry LaMontagne for the patch.
* Fixed Ticket 53. Nested lists no longer isorder items in certain edge cases. ↵Waylan Limberg2010-03-152-0/+22
| | | | Thanks for the report and preliminary work Gerry LaMontagne.
* Fix bug with rawhtml and markdown escaping. Previously, any inline rawhtml ↵Waylan Limberg2010-03-152-1/+3
| | | | that contained text that fit markdown's escaping syntax (i.e. <x\]>) was never unescaped. Now it is. Markdown probably shouldn't be escaping before removing rawhtml in the first place, but this will do for now.
* Updated last failing test as we no longer need a demo of a failing test now ↵Waylan Limberg2010-02-221-2/+2
| | | | that the branch is merged.
* Moved test dir back out of markdown lib. We don't need to install the tests ↵Waylan Limberg2010-02-12141-0/+1649
| | | | in everyones site-packages. We just need to distrubute them in the tarball for people to run before installing etc.
* Moved remaining tests from mergeWaylan Limberg2010-02-124-32/+0
|
* Merged tests branchWaylan Limberg2010-02-12137-1620/+0
|\
| * Moves tests to a subdir of the markdown lib.Waylan Limberg2009-06-05135-1574/+0
| |
| * Initial implementation of nose testing. Still some cleanup to do, but this ↵Waylan Limberg2009-06-053-10/+7
| | | | | | | | shows the differances between the old and the new. Also left one test failing (unsignificant white space only) to demonstrate what a failing test looks like.
* | Cleanup and additional work on previous commit. NOTE: removed special ↵Waylan Limberg2010-01-033-4/+7
| | | | | | | | treatment if raw <div>s with multiple line breaks - they no longer automagicly process their content as markdown. This matches other implementations. Finished rest of code for use by an extension - to be added later.
* | Fixed Ticket 48. Quoted attributes in raw html are specificly ackowledged ↵Waylan Limberg2010-01-032-0/+8
| | | | | | | | | | | | now - allowing various arbitrary stuff (like x/html to be included without breaking the rawhtml parser. Although currently unused, the code also provides the parsed attributes as a dict. Should be useful for adding support for parsing markdown text within rawhtml in an extension.
* | Fixed ticket 44. Raw HTML now maintains original whitespace. Important ↵Waylan Limberg2010-01-032-0/+18
| | | | | | | | inside raw <pre> tags.
* | Fixed Ticket 38. With smart_emphasis turned on, emphasised text can now be ↵Waylan Limberg2009-07-212-0/+14
| | | | | | | | wrapped in punctuation without spaces and still will be converted to emphasis (ie: '[_foo_]'). Test included. Thanks for the report seanh.
* | Fixed ticket 35. Lists now work when padded with five or more spaces after ↵Waylan Limberg2009-06-172-0/+32
|/ | | | 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.
* Improved inline pattern regex for em & strong and added tests. Fixes Ticket ↵Waylan Limberg2009-03-302-0/+30
| | | | 30 and other related issues. Note that I went with php's behavior rather than perl's when we have have three (ie.: *** or ___) without a closing three.
* Completed nested lists and added a test. All tests pass.Waylan Limberg2009-02-042-0/+63
|
* Fixed blockquote test to match previous commit. No space after > now is a ↵Waylan Limberg2009-01-271-3/+5
| | | | blockquote.
* Fixed attribute creation to remove newlines and associated misc/uche test. ↵Waylan Limberg2008-12-081-2/+1
| | | | Apparently differant versions of ElementTree encode line breaks in attributes differantly. Therefore, we just remove any such linebreaks as they are insignificant anyway.
* Fixed para-with-hr test. The code was working correctly, but the test was wrong.Waylan Limberg2008-12-071-2/+3
|
* Adding para-with-hr test. (Broken at the moment.)Yuri Takhteyev2008-12-072-0/+6
|
* Fixed BlockquoteProcessor to acknowledge blocks in which the blockquote ↵Waylan Limberg2008-11-132-2/+18
| | | | starts after the first line. Also updated coresponding test as it had an error and added more detail. All core tests pass now. On to extensions.