Skip to content

Commit 9f8ef82

Browse files
committed
pathological_tests.py: make tests run faster.
- commented out the (already ignored) "many references" test, which times out - reduced the iterations for a couple other tests
1 parent 02c7e76 commit 9f8ef82

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

test/pathological_tests.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -64,17 +64,17 @@
6464
("abc\u0000de\u0000",
6565
re.compile("abc\ufffd?de\ufffd?")),
6666
"backticks":
67-
("".join(map(lambda x: ("e" + "`" * x), range(1,10000))),
67+
("".join(map(lambda x: ("e" + "`" * x), range(1,5000))),
6868
re.compile("^<p>[e`]*</p>\n$")),
6969
"unclosed links A":
70-
("[a](<b" * 50000,
71-
re.compile("(\[a\]\(&lt;b){50000}")),
70+
("[a](<b" * 30000,
71+
re.compile("(\[a\]\(&lt;b){30000}")),
7272
"unclosed links B":
73-
("[a](b" * 50000,
74-
re.compile("(\[a\]\(b){50000}")),
75-
"many references":
76-
("".join(map(lambda x: ("[" + str(x) + "]: u\n"), range(1,50000 * 16))) + "[0] " * 50000,
77-
re.compile("(\[0\] ){49999}"))
73+
("[a](b" * 30000,
74+
re.compile("(\[a\]\(b){30000}")),
75+
# "many references":
76+
# ("".join(map(lambda x: ("[" + str(x) + "]: u\n"), range(1,5000 * 16))) + "[0] " * 5000,
77+
# re.compile("(\[0\] ){4999}"))
7878
}
7979

8080
whitespace_re = re.compile('/s+/')

0 commit comments

Comments
 (0)