Skip to content

Commit 0e5ae6e

Browse files
committed
Add new pathological test for pattern "![[]()"*n.
This was formerly quadratic.
1 parent c5d5721 commit 0e5ae6e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

test/pathological_tests.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ def badhash(ref):
8080
"pattern [ (]( repeated":
8181
(("[ (](" * 40000),
8282
re.compile("(\[ \(\]\(){40000}")),
83+
"pattern ![[]() repeated":
84+
("![[]()" * 160000,
85+
re.compile("(!\[<a href=\"\"></a>){160000}")),
8386
"hard link/emph case":
8487
("**x [a*b**c*](d)",
8588
re.compile("\\*\\*x <a href=\"d\">a<em>b\\*\\*c</em></a>")),

0 commit comments

Comments
 (0)