Skip to content

Commit ade8831

Browse files
committed
Disable doctests on Python 3.11.9+ but not 3.12.
Workaround for python/cpython#117692. Closes #231
1 parent 73d82bf commit ade8831

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

conftest.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import sys
2+
3+
4+
def pytest_configure(config):
5+
disable_broken_doctests(config)
6+
7+
8+
def disable_broken_doctests(config):
9+
"""
10+
Workaround for python/cpython#117692.
11+
"""
12+
if (3, 11, 9) <= sys.version_info < (3, 12):
13+
config.option.doctestmodules = False

0 commit comments

Comments
 (0)