summaryrefslogtreecommitdiff
path: root/Lib/test/libregrtest/setup.py
Commit message (Collapse)AuthorAgeFilesLines
* bpo-38614: Add timeout constants to test.support (GH-16964)Victor Stinner2019-10-301-0/+11
| | | | | | | | Add timeout constants to test.support: * LOOPBACK_TIMEOUT * INTERNET_TIMEOUT * SHORT_TIMEOUT * LONG_TIMEOUT
* bpo-34602: Avoid failures setting macOS stack resource limit (GH-14546)Ned Deily2019-07-021-16/+0
| | | | | | | | | | | | | | | | | Under some conditions the earlier fix for bpo-18075, "Infinite recursion tests triggering a segfault on Mac OS X", now causes failures on macOS when attempting to change stack limit with resource.setrlimit resource.RLIMIT_STACK, like regrtest does when running the test suite. The reverted change had specified a non-default stack size when linking the python executable on macOS. As of macOS 10.14.4, the previous code causes a hard failure when running tests, although similar failures had been seen under some conditions under some earlier systems. Reverting the change to the interpreter stack size at link time helped for release builds but caused some tests to fail when built --with-pydebug. Try the opposite approach: continue to build the interpreter with an increased stack size on macOS and remove the failing setrlimit call in regrtest initialization. This will definitely avoid the resource.RLIMIT_STACK error and should have no, or fewer, side effects.
* bpo-37069: regrtest uses sys.unraisablehook (GH-13759)Victor Stinner2019-06-131-0/+4
| | | | | | | | regrtest now uses sys.unraisablehook() to mark a test as "environment altered" (ENV_CHANGED) if it emits an "unraisable exception". Moreover, regrtest logs a warning in this case. Use "python3 -m test --fail-env-changed" to catch unraisable exceptions in tests.
* bpo-36842: Fix reference leak in tests by running out-of-proc (GH-13556)Steve Dower2019-05-291-21/+26
|
* bpo-36842: Implement PEP 578 (GH-12613)Steve Dower2019-05-231-0/+6
| | | Adds sys.audit, sys.addaudithook, io.open_code, and associated C APIs.
* bpo-36560: Fix reference leak hunting in regrtest (GH-12744)Victor Stinner2019-04-091-6/+0
| | | | | | | | | | | | | | | | | | Fix reference leak hunting in regrtest: compute also deltas (of reference count, allocated memory blocks, file descriptor count) during warmup, to ensure that everything is initialized before starting to hunt reference leaks. Other changes: * Replace gc.collect() with support.gc_collect() * Move calls to read memory statistics from dash_R_cleanup() to dash_R() * Pass regrtest 'ns' to dash_R() * dash_R() is now more quiet with --quiet option (don't display progress). * Precompute the full range for "for it in range(repcount):" to ensure that the iteration doesn't allocate anything new. * dash_R() now is responsible to call warm_caches().
* bpo-32872: Avoid regrtest compatibility issue with namespace packages. (GH-6276)Ned Deily2018-03-281-1/+1
|
* bpo-25588: Fix regrtest when run inside IDLE (#3962)Victor Stinner2017-10-131-12/+31
| | | | | | | When regrtest in run inside IDLE, sys.stdout and sys.stderr are not TextIOWrapper objects and have no file descriptor associated: sys.stderr.fileno() raises io.UnsupportedOperation. Disable faulthandler and don't replace sys.stdout in that case.
* Issue #26295: When using "python3 -m test --testdir=TESTDIR", regrtest doesn'tVictor Stinner2016-03-301-0/+5
| | | | | | add "test." prefix to test module names. regrtest also prepends testdir to sys.path.
* regrtest: Fix module.__path__Victor Stinner2016-03-151-2/+2
| | | | | | | Issue #26538: libregrtest: Fix setup_tests() to keep module.__path__ type (_NamespacePath), don't convert to a list. Add _NamespacePath.__setitem__() method to importlib._bootstrap_external.
* Issue #23919: Prevents assert dialogs appearing in the test suite.Steve Dower2015-10-081-3/+9
|
* Issue #25220, libregrtest: Set support.use_resources in setup_tests()Victor Stinner2015-09-301-1/+3
| | | | | * Rename setup_python() to setup_tests() * Remove use_resources parameter of runtest()
* Issue #25220, libregrtest: Move setup_python() to a new submoduleVictor Stinner2015-09-301-0/+108