diff options
author | Martin Mitas <mity@morous.org> | 2017-08-16 18:00:53 +0200 |
---|---|---|
committer | Martin Mitas <mity@morous.org> | 2017-08-16 18:00:53 +0200 |
commit | 99c5675e2542221cae33cea063f34332ee443cb3 (patch) | |
tree | 4a19c39f3fd6f9b27f38306a4b87419bf350e4d8 /test | |
parent | b9c7a496ba7dd9c3495bae2ff2855899e47b245d (diff) |
Add more pathological tests.
These tests target the issues #214, #218, #220.
Diffstat (limited to 'test')
-rw-r--r-- | test/pathological_tests.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/test/pathological_tests.py b/test/pathological_tests.py index 77e4165..6883c10 100644 --- a/test/pathological_tests.py +++ b/test/pathological_tests.py @@ -58,7 +58,16 @@ pathological = { re.compile("abc\ufffd?de\ufffd?")), "backticks": ("".join(map(lambda x: ("e" + "`" * x), range(1,10000))), - re.compile("^<p>[e`]*</p>\n$")) + re.compile("^<p>[e`]*</p>\n$")), + "unclosed links A": + ("[a](<b" * 50000, + re.compile("(\[a\]\(<b){50000}")), + "unclosed links B": + ("[a](b" * 50000, + re.compile("(\[a\]\(b){50000}")), + "many references": + ("".join(map(lambda x: ("[" + str(x) + "]: u\n"), range(1,50000 * 16))) + "[0] " * 50000, + re.compile("(\[0\] ){49999}")) } whitespace_re = re.compile('/s+/') |