aboutsummaryrefslogtreecommitdiffstats
path: root/tests/extensions/extra
Commit message (Collapse)AuthorAgeFilesLines
* Correct spelling mistakes.Edward Betts2018-01-132-2/+2
|
* Switch from nose to unittestWaylan Limberg2018-01-081-36/+0
| | | | | | | | | | | | | | | All file-based tests are now defined as unittest test cases via a metaclass which walks a directory and builds a unittest for each pair of test files. To run the tests just run `python -m unittest discover tests`. Or use tox as the tox config has been updated to run the new tests and all nose specific code has been removed. The test generator tools have been removed as well. If any changes or additions need to be made to tests, they should be implemented using the new framework rather than with the file-based tests. Eventually, only the PHP and pl tests should remain as file-based tests.
* Fix raw html reference issue (#585)Isaac Muse2018-01-042-0/+186
| | | | | | | | | | | | | | Preserve the line which a reference was on to prevent raw HTML indexing issue. Fixes #584. Prevent raw HTML parsing issue in abbr and footnotes Peserve abbreviation line when stripping and preserve a line for each footnote block. Footnotes should also accumulate the extraneous padding. Test extra lines at the end of references Strip the gathered extraneous whitespace When processing footnotes, we don't actually care to process the extra whitespace at the end of a footnote, but we want it to calculate lines to preserve.
* Fix regression of single column tables (#540)Isaac Muse2017-01-262-2/+129
| | | | | | Single column tables are valid tables, so add back in the accidentally removed functionality of allowing single column tables, but with one exception -- table bodies should not render empty (an empty `<tbody>` is invalid HTML. Fixes #539.
* Fix footnote parsing of footnote content (#536)Isaac Muse2017-01-232-0/+58
| | | | | | | Fixes #412 and #493. First we parse footnote content as its own document avoid quirks with using li as a parent. Second, we surround placeholders with STX and ETX to prevent them from interfering with inline parsing; this is also consistent with how placeholders are used everywhere else in Python Markdown.
* Create additional references for duplicate footnotes (#534)Isaac Muse2017-01-232-0/+22
| | | | | | Track when we find duplicate footnote references and create unique ids for them. Then add an additional tree-processor after inline to go back and update the footnotes with additional back references that link to the duplicate footnote references. Fixes #468.
* Better inline code escaping (#533)Isaac Muse2017-01-202-1/+27
| | | | | This aims to escape code in a more expected fashion. This handles when backticks are escaped and when the escapes before backticks are escaped.
* Tables: Improvements (#530)Isaac Muse2017-01-192-1/+104
| | | | | | | Tables now handle escaped pipes when testing, in table borders, and in the inline content. To achieve properly, a bug had to be fixed related to appending escaped chars to the Markdown class. Now appended chars only appear in the current instance. Lastly the first backtick in a table can be escaped rounding out the last corner case.
* Better handling of backticks in tables (#524)Isaac Muse2017-01-112-1/+40
| | | | At some point the logic of counting backticks and determining if they are odd or even was used to parse a row's text into cells. Unfortunately this approach broke expected code parsing logic in a table. We essentially traded one bug for another. This fixes table backtick handling and restores sane backtick logic while preserving existing fixes. (issue #449)
* lists are not tables - fixes #478 (#507)Adam Wood2016-10-262-3/+13
|
* Fix table alignment when seperator contains spaces (#489)eph2016-08-151-4/+4
| | | | | | | | | | * Fix table alignment when seperator contains spaces eg. seperator like "------ | :----- | :----: | -----: | ------" * Update tests for table * Delete the newline at the end of tables.html
* Add a failing testcase for issue #440.Dmitry Shachnev2015-11-072-1/+22
|
* Fixed handling of table cell splitMustafa Haddara2015-10-242-1/+84
|
* Fix infinite loop #430facelessuser2015-09-042-1/+12
| | | | | | | | | This should fix the remaining corner cases that can cause infinite loops. Previous iterations did not account for scenarios where the “end” index was less than the “start” index. If the “end” index is ever less than or equal to the “start” index, the “end” will be adjusted to to be “start” + 1 allow the full range to be extracted and replaced.
* Fix find footnote placeholder to recurseGustav Tiger2015-08-292-0/+18
|
* updated tables testpieterprovoost2015-04-062-2/+11
|
* added support for zero row tablespieterprovoost2015-04-051-0/+3
|
* Issue #368: Fix Markdown in raw HTML stops workingfacelessuser2014-11-192-3/+24
| | | | | | | Originally there was an infinite loop issue that was patched in issue #308. Unfortunately, it was fixed all the way. This fix patches the infinite loop fix to only add an offset to the `right_listindex` when it is in a infinite loop scenario.
* More updates to test configs.Waylan Limberg2014-08-293-0/+22
| | | | | | | | | | | | | | The last few extensions were updated to accept dicts/**kwargs as configs and more tests were updated. Also updated extra to actually accept configs. Note that extra requires an extra level of dicts. First you need to indicate tha the settings are for extra, then, which extension extra wraps. I'm not crazy abount this, bit not sur ehow else to do it without making all the configs a global attribute on the Markdown class to that any extention can access any other extensions config settings. I don't think we wnat to do that. Also updated extra to use dot notation for the sub-extensions.
* All extension tests now use python dot notation.Waylan Limberg2014-08-291-8/+8
| | | | | | | | | | All named extensions now use python dot notation in the tests - including all builtin extensions (eg: 'extra' => 'markdown.extensions.extra'). This is in anticipation of #336. Note there are a few tests (in the error tests) that will still need updating, but not till we make the change as they will test for the new error message.
* Refactored test framework to use YAML config files rather than INI. Fixes #333.Waylan Limberg2014-08-201-14/+22
|
* Fix issue308 and fix (unrelated) failure to break out of nest loop.ryneeverett2014-05-212-1/+14
|
* Fix some tests failuresDmitry Shachnev2014-02-121-1/+1
|
* tables_and_attr_list testryneeverett2014-01-113-0/+25
|
* Issue #52ryneeverett2013-10-142-6/+57
|
* Ensure each term on def list maintains its own loose status.Waylan Limberg2013-09-022-1/+22
| | | | | | Previously, the code was ignoring whether this was a new term when determining whether the currect item should be loose or not. Fixes #243. Thanks for the report @Anomareh.
* Account for a paragraph that starts with a colon when processing def_listsWaylan Limberg2013-02-062-0/+40
| | | | Fixes #171. While that report provided an example of an unordered list item that started with a colon, any block that starts with a colon and has no siblings before it (paragraph as begining if document, list item, etc) all exhibit this same behavior. Following PHP Markdown Extra's lead, these are not definition items as they have no term before them.
* Fix `footnote_many_footnotes` test as per #129Dmitry Shachnev2012-08-251-2398/+2398
|
* Fixed #129. Footnotes now output valid HTML5.Waylan Limberg2012-08-093-15/+15
| | | | | | | | | | | | | | | | As HTML5 has depreciated use of `rev=anything` and `rel=footnotes`, they are no longer inlcuded in the output when the output_format is set to HTML5. Note that if someone successful registers a spec for `rel=footnotes` in the future (as a microformat), then that could be considered valid. But until that happens, it is invlaid to use in HTML5. Therefore, we remove it from the output (when outputing HTML% only). As an alternative, two new classes are set (in all output_formats). On the link to the footnote (where `rel=footnotes` was used), we set `class=footnote-ref` and on the backlink (where `rev=footnote` was used), we set `class=footnote-backref`. Also updated the tests to reflect to the new classes in the output.
* Some more tests for issue #51. An upate to Marcin Kasperski's tests (which I ↵Waylan Limberg2011-11-173-2402/+1212
| | | | previously merged). Thanks Marcin. Also added a test for not-indented secondary lines of a first paragraph in a footnote definition.
* Merge git://github.com/Mekk/Python-Markdown into mekkWaylan Limberg2011-11-172-0/+10796
|\
| * Example test for #51 (crash on docs with +1000 footnotes)Marcin Kasperski2011-11-102-0/+10796
| |
* | Fixed #51. Removed recussion from footnote preproccessor. Also refactors the ↵Waylan Limberg2011-11-183-14/+7
|/ | | | code to provide a few other minor improvements s that output more closely matches php's output. Thus the changes in the tests.
* Fixed #30. Tables now allow three spaces of indent like PHP Markdown Extra. ↵Waylan Limberg2011-06-292-1/+62
| | | | Thanks to skurfer for report and inital patch.
* Added our own xhtml searializer. We no longer use a xml searializer to ↵Waylan Limberg2011-06-161-6/+6
| | | | 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 Ticket 70 and added a test. Footnote references whithout a ↵Waylan Limberg2010-08-252-0/+3
| | | | coresponding definition no longer raise an error. They now pass through as plain text - which is the same behavior as PHP Markdown Extra. Thanks for the report Benjamin Bach.
* Fixed problem hidden by Ticket 68. Defining a footnote placeholder in a ↵Waylan Limberg2010-08-022-0/+15
| | | | markdown document results in the placeholder actually being replaced. Also added a test for this. Note that if the placeholder paragraph has other text, that text is lost. Not sure if this is a bug or bad markdown syntax.
* Fixed Ticket 60. The dd in definition lists can now not be indented on ↵Waylan Limberg2010-03-242-0/+12
| | | | secondary lines.
* Moved test dir back out of markdown lib. We don't need to install the tests ↵Waylan Limberg2010-02-1217-0/+2012
in everyones site-packages. We just need to distrubute them in the tarball for people to run before installing etc.