Skip to content

Commit 14e539f

Browse files
authored
gh-111809: Fix test_deep_repr from test_userdict on WASI (GH-112229)
1 parent 10e1a0c commit 14e539f

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Lib/test/test_userdict.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Check every path through every method of UserDict
22

3-
from test import mapping_tests
3+
from test import mapping_tests, support
44
import unittest
55
import collections
66

@@ -213,6 +213,11 @@ class G(collections.UserDict):
213213
else:
214214
self.fail("g[42] didn't raise KeyError")
215215

216+
# Decorate existing test with recursion limit, because
217+
# the test is for C structure, but `UserDict` is a Python structure.
218+
test_repr_deep = support.infinite_recursion()(
219+
mapping_tests.TestHashMappingProtocol.test_repr_deep,
220+
)
216221

217222

218223
if __name__ == "__main__":

0 commit comments

Comments
 (0)