Commit Graph

515 Commits

Author SHA1 Message Date
Victor Stinner 3aac0adfe0 Cleanup regrtest "main()" function
* Rename libregrtest.main_in_temp_cwd() to libregrtest.main()
* Add regrtest.main_in_temp_cwd() alias to libregrtest.main()
* Move old main_in_temp_cwd() code into libregrtest.Regrtest.main()
* Update multiple scripts to call libregrtest.main()
2016-03-24 17:53:20 +01:00
Victor Stinner 4ffcc3ee1e Cleanup regrtest.py
* Move code into a new _main() function
* Fix loop to cleanup sys.path
* Remove unused import
2016-03-24 17:43:53 +01:00
Serhiy Storchaka fc632e3912 Merge with 3.5. 2015-10-06 18:52:52 +03:00
Brett Cannon be7c1638e2 Issue #25188: Add a -P/--pgo flag to regrtest to silence error output.
Since PGO building doesn't care about test failures, silence them when
running the test suite for performance reasons. Initial patch by
Alecsandru Patrascu of Intel.
2015-10-02 16:16:44 -07:00
Victor Stinner 36b3fbb0ee Issue #25220: Fix Lib/test/autotest.py 2015-09-27 11:19:08 +02:00
Victor Stinner 3844fe5ed8 Issue #25220: Move most regrtest.py code to libregrtest 2015-09-26 10:38:01 +02:00
Victor Stinner 98de5340d4 Issue #25220: Create Lib/test/libregrtest/
Start to split regrtest.py into smaller parts with the creation of
Lib/test/libregrtest/cmdline.py: code to handle the command line, especially
parsing command line arguments. This part of the code is tested by
test_regrtest.
2015-09-26 09:43:45 +02:00
Victor Stinner 0cca00b67e Issue #25220: Backed out changeset eaf9a99b6bb8 2015-09-23 23:16:47 +02:00
Victor Stinner 7b92abf0e9 Issue #25220: Create Lib/test/libregrtest/
Start to split regrtest.py into smaller parts with the creation of
Lib/test/libregrtest/cmdline.py.
2015-09-23 23:04:18 +02:00
Zachary Ware 83ee5a315f Merge 3.4 2015-08-08 22:03:43 -05:00
Zachary Ware 9a47ed8839 regrtest: the 'bad' and 'environment_changed' sets of tests don't intersect anymore 2015-08-08 22:03:27 -05:00
Zachary Ware 920a335e97 Issue #24751: When running regrtest with '-w', don't fail if re-run succeeds. 2015-08-04 21:54:54 -05:00
Zachary Ware 40648838b2 Issue #24751: Merge with 3.4 2015-08-04 21:58:00 -05:00
Serhiy Storchaka e98209c2b4 Issue #24245: Eliminated senseless expect clauses that have no any effect.
Patch by Martin Panter.
2015-05-20 16:10:04 +03:00
Serhiy Storchaka 10915aa85c Issue #22390: test.regrtest now emits a warning if temporary files or
directories are left after running a test.
2015-03-30 01:30:22 +03:00
Serhiy Storchaka a3a100b594 Issue #22390: test.regrtest now emits a warning if temporary files or
directories are left after running a test.
2015-03-30 01:28:02 +03:00
Victor Stinner 5d575399bc Issue #23145: regrtest now shows errors and raises an exception if
loader.loadTestsFromModule() logged errors.
2015-01-06 14:05:03 +01:00
Zachary Ware 69fb6a41c5 Issue #22104: Don't hold a reference to the loaded TestSuite in runtest_inner 2014-08-04 11:15:10 -05:00
Benjamin Peterson f617fa88de merge 3.3 2014-02-16 14:53:55 -05:00
Benjamin Peterson cf62603276 backout fafac90b69c4 2014-02-16 14:52:01 -05:00
Benjamin Peterson a118c4fa79 merge 3.3 2014-01-09 11:12:31 -06:00
Benjamin Peterson 50b82c765f clear zip stat cache after each ref leak run 2014-01-09 11:10:30 -06:00
Christian Heimes 985ecdcfc2 ssue #19183: Implement PEP 456 'secure and interchangeable hash algorithm'.
Python now uses SipHash24 on all major platforms.
2013-11-20 11:46:18 +01:00
Eli Bendersky e8de29669d Remove unused --debug option of regrtest.
If bots fail due to using this flag, the buildbot scripts have to be modified
to omit it. Regrtest ignores it anyway.
2013-09-02 17:01:10 -07:00
Eli Bendersky e5eebedd55 Fix docstring and some indentation 2013-09-02 16:52:25 -07:00
Eli Bendersky 7f5c22c022 Refactor the main function of regrtest a bit.
Moving subprocess execution of tests into a function.
2013-09-02 08:57:21 -07:00
Andrew Svetlov 8913a6c83d Issue #11798: fix tests for regrtest -R : 2013-09-01 07:58:41 +03:00
Richard Oudkerk 83d7dea6aa Issue #8713: Cleanup before saving process._dangling. 2013-08-29 12:51:11 +01:00
Serhiy Storchaka 64f7c4e4ca Issue #16799: Switched from getopt to argparse style in regrtest's argument
parsing.  Added more tests for regrtest's argument parsing.
2013-08-29 12:26:23 +03:00
Richard Oudkerk 84ed9a68bd Issue #8713: Support alternative start methods in multiprocessing on Unix.
See http://hg.python.org/sandbox/sbt#spawn
2013-08-14 15:35:41 +01:00
Florent Xicluna 8624ed502f Issue #18375: merge with 3.3 2013-07-06 12:27:50 +02:00
Florent Xicluna d9e7c86d7e Issue #18375: Assume --randomize when --randseed is used for running the testsuite. 2013-07-06 12:25:52 +02:00
Brett Cannon 260fbe80c5 Issue #15767: Excise the remaining instances of ModuleNotFoundError 2013-07-04 18:16:15 -04:00
Charles-François Natali 37cfb0a920 Issue #17914: Use os.cpu_count() instead of multiprocessing.cpu_count() where
applicable.
2013-06-28 19:25:45 +02:00
Victor Stinner 383a820e0d Issue #17206: test.regrtest and test.script_helper enable faulthandler module
in subprocesses.
2013-06-25 21:24:36 +02:00
Victor Stinner 546ccf090e Issue #18228: Use locale.setlocale(name, None) instead of
locale.getlocale(name) in test.regrtest.saved_test_environment

locale.getlocale() parses the locale, which is useless for
saved_test_environment.
2013-06-17 21:28:14 +02:00
Victor Stinner d9ccf7fe22 Issue #18228: Fix locale test of test.regrtest.saved_test_environment
Skip LC_ALL becore getlocale(locale.LC_ALL) always fail, and catch also
ValueError.
2013-06-17 20:40:05 +02:00
Victor Stinner a222de1a23 (Merge 3.3) regrtest.py: Fix another typo in the usage of the faulthandler module 2013-06-17 20:35:42 +02:00
Victor Stinner 934676afba regrtest.py: Fix another typo in the usage of the faulthandler module 2013-06-17 20:35:08 +02:00
Victor Stinner 4a704d2341 (Merge 3.3) regrtest.py: Fix typo in the usage of the faulthandler module 2013-06-17 20:28:02 +02:00
Victor Stinner 4de701b728 regrtest.py: Fix typo in the usage of the faulthandler module 2013-06-17 20:27:10 +02:00
Brett Cannon 6d26eba186 Check that warnings.showwarning() is not changed. 2013-06-16 15:20:48 -04:00
Brett Cannon c9a1bfed5d Move test___all__ over to unittest.main() and use ModuleNotFoundError 2013-06-12 20:12:30 -04:00
Brett Cannon 49e835bec6 Issue #14135: Let's try this again. 2013-04-01 14:11:37 -04:00
Antoine Pitrou 7d197de987 Backed out changeset 4fcd50a6dca7 as it totally breaks the test suite here. 2013-04-01 18:54:45 +02:00
Brett Cannon 2d556f56db Issue #14135: Make sure tests don't leave the locale changed for any
category.

Thanks to Westley Martinez for trying to fix the issue and Atsuo
Ishimoto for an initial patch.
2013-04-01 12:53:13 -04:00
Chris Jerdonek 517e925614 Issue #17283: Share code between __main__.py and regrtest.py in Lib/test.
This commit also removes TESTCWD from regrtest.py's global namespace.
2013-02-27 09:02:53 -08:00
R David Murray 14d080eaa1 #16259: delete some no-longer-used code from regrtest.
dash_R is only called from one location, and from that location
an indirect_test is passed.
2013-01-12 11:34:38 -05:00
Chris Jerdonek 15738427f6 Issue #16854: Fix regrtest.usage() regression introduced in 6e2e5adc0400.
This fixes a regression introduced in the commit for issue #15302, which
switched regrtest from getopt to argparse.
2013-01-07 17:07:32 -08:00
Chris Jerdonek d6c18dcd20 Issue #15302: Switch regrtest from using getopt to using argparse.
This is the first step in refactoring regrtest to use argparse.  The
regrtest module's main() function still expects a getopt-style return
value rather than an argparse.Namespace instance.
2012-12-27 18:53:12 -08:00