]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.11] gh-112155: Run `typing.py` doctests during tests (GH-112156) (#112231)
authorNikita Sobolev <mail@sobolevn.me>
Sat, 18 Nov 2023 11:13:55 +0000 (14:13 +0300)
committerGitHub <noreply@github.com>
Sat, 18 Nov 2023 11:13:55 +0000 (11:13 +0000)
Lib/test/test_typing.py

index 30056e49ae29d9583f7b708f92189b49e78b24cf..12f78b580effaaddacc45328528ebb6763683e4c 100644 (file)
@@ -8466,5 +8466,11 @@ class TypeIterationTests(BaseTestCase):
             self.assertNotIsInstance(type_to_test, collections.abc.Iterable)
 
 
+def load_tests(loader, tests, pattern):
+    import doctest
+    tests.addTests(doctest.DocTestSuite(typing))
+    return tests
+
+
 if __name__ == '__main__':
     main()