summaryrefslogtreecommitdiffstats
path: root/Lib/test/support.py
Commit message (Collapse)AuthorAgeFilesLines
...
* | More informative skip message in @bigaddrspaceAntoine Pitrou2011-01-121-3/+7
| |
* | Fix @bigmemtest when no limit is given by the user (oops)Antoine Pitrou2011-01-121-1/+1
| |
* | Make test skipping message nicer, and remove the rather useless "overhead" ↵Antoine Pitrou2011-01-121-20/+10
| | | | | | | | parameter.
* | Typo.Eric Smith2011-01-111-1/+1
| |
* | Issue 10556: test_zipimport_support implicitly imports too many modules ↵Nick Coghlan2011-01-111-0/+6
| | | | | | | | (including _ssl) to safely clobber sys.modules after each test
* | Add EHOSTUNREACH ('No route to host') to the errnos trapped by ↵Antoine Pitrou2011-01-081-0/+1
| | | | | | | | transient_internet().
* | Fix #9333 on Windows XP, where os.symlink is not a possibility.Brian Curtin2010-12-291-1/+1
| |
* | Fix #9333. The symlink function is always available now, raising OSErrorBrian Curtin2010-12-281-1/+21
| | | | | | | | when the user doesn't hold the symbolic link privilege rather than hiding it.
* | Issue #10188 (partial resolution): tidy up some behaviour in the new ↵Nick Coghlan2010-12-121-0/+3
| | | | | | | | tempfile.TemporaryDirectory context manager
* | Fied typoVinay Sajip2010-12-101-1/+1
| |
* | test.support: Added TestHandler and Matcher classes for better support of ↵Vinay Sajip2010-12-101-2/+68
| | | | | | | | assertions about logging.
* | More issue #10624: Add requires_IEEE_754 to __all__.Eric Smith2010-12-041-1/+1
| |
* | Issue #10624: Move requires_IEEE_754 into test.support. I'll fix up other ↵Eric Smith2010-12-041-0/+5
| | | | | | | | uses of it shortly.
* | Fix #9333. Expose os.symlink on Windows only when usable.Brian Curtin2010-12-021-22/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to create symlinks on Windows, SeCreateSymbolicLinkPrivilege is an account privilege that is required to be held by the user. Not only must the privilege be enabled for the account, the activated privileges for the currently running application must be adjusted to enable the requested privilege. Rather than exposing an additional function to be called prior to the user's first os.symlink call, we handle the AdjustTokenPrivileges Windows API call internally and only expose os.symlink when the privilege escalation was successful. Due to the change of only exposing os.symlink when it's available, we can go back to the original test skipping methods of checking via `hasattr`.
* | PY_CFLAGS doesn't exist under WindowsAntoine Pitrou2010-10-311-1/+1
| |
* | make gdb skip expectedBenjamin Peterson2010-10-291-0/+13
| |
* | Make check_warnings error messages more informativeAntoine Pitrou2010-10-291-7/+7
| |
* | Replace the "compiler" resource with the more generic "cpu", soAntoine Pitrou2010-10-141-1/+1
| | | | | | | | as to mark CPU-heavy tests.
* | Inherit interpreter flags in parallel testingAntoine Pitrou2010-10-141-0/+19
| |
* | test_sys: Remove workaround #8611Victor Stinner2010-10-131-8/+0
| | | | | | | | | | It looks like it is no more needed: Python 3.2 is slowly able to support non-ascii paths with an ascii locale.
* | Issue #9819: fix TESTFN_UNENCODABLE for japanese code pageVictor Stinner2010-09-101-2/+3
| |
* | Also catch some gaierrorsAntoine Pitrou2010-09-071-1/+10
| |
* | Improve transient_internet() again to detect more network errors,Antoine Pitrou2010-09-071-8/+24
| | | | | | | | and use it in test_robotparser. Fixes #8574.
* | Issue #8574: better implementation of test.support.transient_internet().Antoine Pitrou2010-09-071-7/+31
| | | | | | | | Original patch by Victor.
* | Workaround issue #8611 in test_undecodable_code() of test_sysVictor Stinner2010-08-201-0/+8
| | | | | | | | | | Write test.support.workaroundIssue8611() function so it will be easier to remove this workaround from all tests.
* | Decompose TESTFN_UNICODE on Mac OS XVictor Stinner2010-08-181-0/+6
| |
* | Improve PEP 383 tests (in test_os)Victor Stinner2010-08-181-4/+2
| | | | | | | | | | | | | | | | | | | | | | * Use the current filesystem encoding instead of always using utf-8 * Enable the test on Mac OS X * Use TESTFN_UNENCODABLE and TESTFN_UNICODE instead of arbitrary filenames * To decode a filename, use strict error handler instead surrogateescape for mbcs encoding (on Windows) * Use TESTFN_UNENCODABLE (if available) for the directory name Skip the test if no non-ascii filename can be created.
* | Issue #8202: Set sys.argv[0] to -m rather than -c while searching for the ↵Nick Coghlan2010-08-171-9/+20
| | | | | | | | module to execute. Also updates all the cmd_line_script tests to validate the setting of sys.path[0] and the current working directory
* | Fix TESTFN_UNENCODABLE of test.support on Mac OS XVictor Stinner2010-08-151-6/+5
| |
* | Mac OS X denies unencodable filenames (invalid utf-8)Victor Stinner2010-08-141-1/+2
| |
* | Fix a typo: TESTFN_UNENCODEABLE => TESTFN_UNENCODABLEVictor Stinner2010-08-131-8/+8
| |
* | Oops, I did it again: add missing \ removed in previous commitVictor Stinner2010-08-131-1/+1
| |
* | Oops, create TESTFN_UNENCODEABLE from TEST_FN, not TESTFN_UNICODEVictor Stinner2010-08-131-1/+1
| | | | | | | | | | test_imp fails on Linux with C locale because TESTFN_UNICODE is not encodable to ascii.
* | Set TESTFN_UNENCODEABLE on non-Windows OSesVictor Stinner2010-08-131-20/+29
| | | | | | | | | | | | | | * Use 0xff byte on non-Windows OSes * mbcs is now really strict by default: i closed the issue #850997, so use the filesystem encoding and not Latin-1 * Rename TESTFN_UNICODE_UNENCODEABLE to TESTFN_UNENCODEABLE
* | Factor out stripping of interpreter debug output in ↵Antoine Pitrou2010-08-041-0/+10
| | | | | | | | test.support.strip_python_stderr()
* | Set sys.modules[name] to None instead of 0 to block module import.Alexander Belopolsky2010-07-131-1/+1
| |
* | Implement #1578269. Patch by Jason R. Coombs.Brian Curtin2010-07-081-2/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added Windows support for os.symlink when run on Windows 6.0 or greater, aka Vista. Previous Windows versions will raise NotImplementedError when trying to symlink. Includes numerous test updates and additions to test_os, including a symlink_support module because of the fact that privilege escalation is required in order to run the tests to ensure that the user is able to create symlinks. By default, accounts do not have the required privilege, so the escalation code will have to be exposed later (or documented on how to do so). I'll be following up with that work next. Note that the tests use ctypes, which was agreed on during the PyCon language summit.
* | Fix error handling removing files in test.support.unlinkMichael Foord2010-05-041-1/+2
| |
* | Issue #8533: revert r80694; try a different fix: regrtest uses backslashreplaceVictor Stinner2010-05-021-1/+1
| | | | | | | | | | error handler for stdout to avoid UnicodeEncodeError (write non-ASCII character to stdout using ASCII encoding)
* | Issue #8533: Write tracebacks and failed tests to sys.stderr instead ofVictor Stinner2010-05-021-1/+1
| | | | | | | | sys.stdout to avoid UnicodeEncodeError (use backslashreplace error handler)
* | Merged revisions 80552-80556,80564-80566,80568-80571 via svnmerge fromVictor Stinner2010-04-281-4/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r80552 | victor.stinner | 2010-04-27 23:46:03 +0200 (mar., 27 avril 2010) | 3 lines Issue #7449, part 1: fix test_support.py for Python compiled without thread ........ r80553 | victor.stinner | 2010-04-27 23:47:01 +0200 (mar., 27 avril 2010) | 1 line Issue #7449, part 2: regrtest.py -j option requires thread support ........ r80554 | victor.stinner | 2010-04-27 23:51:26 +0200 (mar., 27 avril 2010) | 9 lines Issue #7449 part 3, test_doctest: import trace module in test_coverage() Import trace module fail if the threading module is missing. test_coverage() is only used if test_doctest.py is used with the -c option. This commit allows to execute the test suite without thread support. Move "import trace" in test_coverage() and use test_support.import_module('trace'). ........ r80555 | victor.stinner | 2010-04-27 23:56:26 +0200 (mar., 27 avril 2010) | 6 lines Issue #7449, part 4: skip test_multiprocessing if thread support is disabled import threading after _multiprocessing to raise a more revelant error message: "No module named _multiprocessing". _multiprocessing is not compiled without thread support. ........ r80556 | victor.stinner | 2010-04-28 00:01:24 +0200 (mer., 28 avril 2010) | 8 lines Issue #7449, part 5: split Test.test_open() of ctypes/test/test_errno.py * Split Test.test_open() in 2 functions: test_open() and test_thread_open() * Skip test_open() and test_thread_open() if we are unable to find the C library * Skip test_thread_open() if thread support is disabled * Use unittest.skipUnless(os.name == "nt", ...) on test_GetLastError() ........ r80564 | victor.stinner | 2010-04-28 00:59:35 +0200 (mer., 28 avril 2010) | 4 lines Issue #7449, part 6: fix test_hashlib for missing threading module Move @test_support.reap_thread decorator from test_main() to test_threaded_hashing(). ........ r80565 | victor.stinner | 2010-04-28 01:01:29 +0200 (mer., 28 avril 2010) | 6 lines Issue #7449, part 7: simplify threading detection in test_capi * Skip TestPendingCalls if threading module is missing * Test if threading module is present or not, instead of test the presence of _testcapi._test_thread_state ........ r80566 | victor.stinner | 2010-04-28 01:03:16 +0200 (mer., 28 avril 2010) | 4 lines Issue #7449, part 8: don't skip the whole test_asynchat if threading is missing TestFifo can be executed without the threading module ........ r80568 | victor.stinner | 2010-04-28 01:14:58 +0200 (mer., 28 avril 2010) | 6 lines Issue #7449, part 9: fix test_xmlrpclib for missing threading module * Skip testcases using threads if threading module is missing * Use "http://" instead of URL in ServerProxyTestCase if threading is missing because URL is not set in this case ........ r80569 | victor.stinner | 2010-04-28 01:33:58 +0200 (mer., 28 avril 2010) | 6 lines Partial revert of r80556 (Issue #7449, part 5, fix ctypes test) Rewrite r80556: the thread test have to be executed just after the test on libc_open() and so the test cannot be splitted in two functions (without duplicating code, and I don't want to duplicate code). ........ r80570 | victor.stinner | 2010-04-28 01:51:16 +0200 (mer., 28 avril 2010) | 8 lines Issue #7449, part 10: test_cmd imports trace module using test_support.import_module() Use test_support.import_module() instead of import to raise a SkipTest exception if the import fail. Import trace fails if the threading module is missing. See also part 3: test_doctest: import trace module in test_coverage(). ........ r80571 | victor.stinner | 2010-04-28 01:55:59 +0200 (mer., 28 avril 2010) | 6 lines Issue #7449, last part (11): fix many tests if thread support is disabled * Use try/except ImportError or test_support.import_module() to import thread and threading modules * Add @unittest.skipUnless(threading, ...) to testcases using threads ........
* | Merged revisions 80314-80315 via svnmerge fromAntoine Pitrou2010-04-211-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r80314 | antoine.pitrou | 2010-04-21 21:28:03 +0200 (mer., 21 avril 2010) | 5 lines Issue #8484: Load all ciphers and digest algorithms when initializing the _ssl extension, such that verification of some SSL certificates doesn't fail because of an "unknown algorithm". ........ r80315 | antoine.pitrou | 2010-04-21 21:36:23 +0200 (mer., 21 avril 2010) | 3 lines Forgot to add the sample certificate (followup to r80314) ........
* | PEP 3147Barry Warsaw2010-04-171-26/+64
| |
* | Merged revisions 79934 via svnmerge fromBenjamin Peterson2010-04-111-1/+3
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r79934 | philip.jenvey | 2010-04-10 14:39:07 -0500 (Sat, 10 Apr 2010) | 1 line adjust gc_collect for Jython ........
* | Merged revisions 78982,78986 via svnmerge fromFlorent Xicluna2010-03-191-3/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r78982 | florent.xicluna | 2010-03-15 15:00:58 +0100 (lun, 15 mar 2010) | 2 lines Remove py3k deprecation warnings from these Unicode tools. ........ r78986 | florent.xicluna | 2010-03-15 19:08:58 +0100 (lun, 15 mar 2010) | 3 lines Issue #7783 and #7787: open_urlresource invalidates the outdated files from the local cache. Use this feature to fix test_normalization. ........
* | Merged revisions 79049 via svnmerge fromFlorent Xicluna2010-03-181-3/+8
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r79049 | florent.xicluna | 2010-03-18 20:51:47 +0100 (jeu, 18 mar 2010) | 2 lines #8155: Preserve backward compatibility for test_support.check_warnings(). Add regression tests. ........
* | Add some tests for ways users can change or shadow globals and builtins.Collin Winter2010-03-171-1/+56
| |
* | Merged revisions 78838-78839,78917,78919,78934,78937 via svnmerge fromFlorent Xicluna2010-03-131-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r78838 | florent.xicluna | 2010-03-11 15:36:19 +0100 (jeu, 11 mar 2010) | 2 lines Issue #6472: The xml.etree package is updated to ElementTree 1.3. The cElementTree module is updated too. ........ r78839 | florent.xicluna | 2010-03-11 16:55:11 +0100 (jeu, 11 mar 2010) | 2 lines Fix repr of tree Element on windows. ........ r78917 | florent.xicluna | 2010-03-13 12:18:49 +0100 (sam, 13 mar 2010) | 2 lines Move the xml test data to their own directory. ........ r78919 | florent.xicluna | 2010-03-13 13:41:48 +0100 (sam, 13 mar 2010) | 2 lines Do not chdir when running test_xml_etree, and enhance the findfile helper. ........ r78934 | florent.xicluna | 2010-03-13 18:56:19 +0100 (sam, 13 mar 2010) | 2 lines Update some parts of the xml.etree documentation. ........ r78937 | florent.xicluna | 2010-03-13 21:30:15 +0100 (sam, 13 mar 2010) | 3 lines Add the keyword argument "method=None" to the .write() method and the tostring/tostringlist functions. Update the function, class and method signatures, according to the new convention. ........
* | Only the parts which are relevant for 3.x branch.Florent Xicluna2010-03-131-7/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merged revisions 78757-78758,78769,78815 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r78757 | florent.xicluna | 2010-03-07 13:14:25 +0100 (dim, 07 mar 2010) | 2 lines Fix some py3k warnings in the standard library. ........ r78758 | florent.xicluna | 2010-03-07 13:18:33 +0100 (dim, 07 mar 2010) | 4 lines Issue #7849: Now the utility ``check_warnings`` verifies if the warnings are effectively raised. A new utility ``check_py3k_warnings`` deals with py3k warnings. ........ r78769 | florent.xicluna | 2010-03-07 20:14:12 +0100 (dim, 07 mar 2010) | 2 lines Refresh the documentation for the test.test_support module. ........ r78815 | florent.xicluna | 2010-03-09 20:57:01 +0100 (mar, 09 mar 2010) | 2 lines #7772: Fix test_py3kwarn. Now the test suite could pass with "-3" flag. ........
* | Merged revisions 78136 via svnmerge fromEzio Melotti2010-02-181-19/+33
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r78136 | ezio.melotti | 2010-02-10 23:40:33 +0200 (Wed, 10 Feb 2010) | 1 line #7712: add a temp_cwd context manager to test_support and use it in regrtest to run all the tests in a temporary directory, saving the original CWD in test_support.SAVEDCWD. Thanks to Florent Xicluna who helped with the patch. ........