Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
69fb6a41
Commit
69fb6a41
authored
Aug 04, 2014
by
Zachary Ware
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #22104: Don't hold a reference to the loaded TestSuite in runtest_inner
parent
d5774801
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
2 deletions
+7
-2
Lib/test/regrtest.py
Lib/test/regrtest.py
+4
-2
Misc/NEWS
Misc/NEWS
+3
-0
No files found.
Lib/test/regrtest.py
View file @
69fb6a41
...
...
@@ -1273,8 +1273,10 @@ def runtest_inner(test, verbose, quiet,
# tests. If not, use normal unittest test loading.
test_runner = getattr(the_module, "
test_main
", None)
if test_runner is None:
tests = unittest.TestLoader().loadTestsFromModule(the_module)
test_runner = lambda: support.run_unittest(tests)
def test_runner():
loader = unittest.TestLoader()
tests = loader.loadTestsFromModule(the_module)
support.run_unittest(tests)
test_runner()
if huntrleaks:
refleak = dash_R(the_module, test, test_runner, huntrleaks)
...
...
Misc/NEWS
View file @
69fb6a41
...
...
@@ -239,6 +239,9 @@ IDLE
Tests
-----
- Issue #22104: regrtest.py no longer holds a reference to the suite of tests
loaded from test modules that don't define test_main().
- Issue #22002: Added ``load_package_tests`` function to test.support and used
it to implement/augment test discovery in test_asyncio, test_email,
test_importlib, test_json, and test_tools.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment