summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_sys.py
Commit message (Collapse)AuthorAgeFilesLines
* #11565: Merge with 3.1.Ezio Melotti2011-03-161-1/+1
|\
| * #11565: Fix several typos. Patch by Piotr Kasprzyk.Ezio Melotti2011-03-161-1/+1
| |
| * Merged revisions 86596 via svnmerge fromEzio Melotti2010-11-211-8/+8
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r86596 | ezio.melotti | 2010-11-20 21:04:17 +0200 (Sat, 20 Nov 2010) | 1 line #9424: Replace deprecated assert* methods in the Python test suite. ........
| * Merged revisions ↵Florent Xicluna2010-08-141-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 83212,83829,83833,83838-83839,83878,84019,84025,84028,84032,84036 via svnmerge from svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r83212 | florent.xicluna | 2010-07-28 18:39:41 +0200 (mer., 28 juil. 2010) | 2 lines Syntax cleanup. ........ r83829 | florent.xicluna | 2010-08-08 18:16:07 +0200 (dim., 08 août 2010) | 2 lines Use unittest specific methods for some urllib test cases. And replace urllib2 with urllib.request in comments. ........ r83833 | florent.xicluna | 2010-08-08 18:25:27 +0200 (dim., 08 août 2010) | 2 lines Add test case for the HTTPResponse being an iterable. Follow-up of issue #4608. ........ r83838 | florent.xicluna | 2010-08-08 20:03:44 +0200 (dim., 08 août 2010) | 2 lines Typo. ........ r83839 | florent.xicluna | 2010-08-08 20:06:13 +0200 (dim., 08 août 2010) | 2 lines Issue #7564: Skip test_ioctl if another process is attached to /dev/tty. ........ r83878 | florent.xicluna | 2010-08-09 10:29:08 +0200 (lun., 09 août 2010) | 1 line Merge the 2to3 script from /sandbox/trunk/2to3/2to3, revision 72867 (latest). ........ r84019 | florent.xicluna | 2010-08-14 17:56:42 +0200 (sam., 14 août 2010) | 11 lines Merged manually from 2.7 branch to 3.x trunk. ------------------------------------------------------------------------ r79925 | nick.coghlan | 2010-04-10 16:24:36 +0200 (sam. 10 avril 2010) Try to turn some buildbots green by allowing test_multiprocessing to pass even if it hits the sys.exc_clear code in the threading module, and improve the test coverage by making the ctypes dependencies a bit more granular (two of the cited ctypes objects don't exist on my system) ------------------------------------------------------------------------ ........ r84025 | florent.xicluna | 2010-08-14 18:56:27 +0200 (sam., 14 août 2010) | 1 line List Misc/python-config.in in Misc/README. Fix few typos. ........ r84028 | florent.xicluna | 2010-08-14 19:02:49 +0200 (sam., 14 août 2010) | 1 line Fix order. ........ r84032 | florent.xicluna | 2010-08-14 19:15:31 +0200 (sam., 14 août 2010) | 1 line Convert to spaces. ........ r84036 | florent.xicluna | 2010-08-14 20:03:19 +0200 (sam., 14 août 2010) | 1 line Remove bad merge (from svnmerge r82301) ........
| * Merged revisions 83140-83141 via svnmerge fromAlexander Belopolsky2010-07-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r83140 | alexander.belopolsky | 2010-07-25 11:02:55 -0400 (Sun, 25 Jul 2010) | 5 lines Issue #9315: Renamed test_trace to test_sys_settrace and test_profilehooks to test_sys_setprofile so that test_trace can be used for testing the trace module and for naming consistency. ........ r83141 | alexander.belopolsky | 2010-07-25 11:05:42 -0400 (Sun, 25 Jul 2010) | 1 line Corrected comments on where settrace and setprofile are tested. ........
| * Reverted r83143: svnmerge failed to add new namesAlexander Belopolsky2010-07-251-2/+2
| |
| * Merged revisions 83140-83141 via svnmerge fromAlexander Belopolsky2010-07-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r83140 | alexander.belopolsky | 2010-07-25 11:02:55 -0400 (Sun, 25 Jul 2010) | 5 lines Issue #9315: Renamed test_trace to test_sys_settrace and test_profilehooks to test_sys_setprofile so that test_trace can be used for testing the trace module and for naming consistency. ........ r83141 | alexander.belopolsky | 2010-07-25 11:05:42 -0400 (Sun, 25 Jul 2010) | 1 line Corrected comments on where settrace and setprofile are tested. ........
| * Backport test_getfilesystemencoding() from py3kVictor Stinner2010-06-111-0/+30
| | | | | | | | Note: On Python 3.1, file system encoding can be None.
| * Merged revisions 81276 via svnmerge fromVictor Stinner2010-05-171-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r81276 | victor.stinner | 2010-05-17 21:57:40 +0200 (lun., 17 mai 2010) | 4 lines Fix test_main_invalid_unicode() of test_sys for ASCII locale encoding It should fix sparc 3.x and 3.1 failures. ........
| * Merged revisions 81267 via svnmerge fromVictor Stinner2010-05-171-1/+2
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r81267 | victor.stinner | 2010-05-17 16:36:43 +0200 (lun., 17 mai 2010) | 2 lines Improve test_exit() error message to analyze sparc failures ........
| * Merged revisions 81250-81253 via svnmerge fromVictor Stinner2010-05-171-1/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r81250 | victor.stinner | 2010-05-17 03:13:37 +0200 (lun., 17 mai 2010) | 2 lines Issue #6697: Fix a crash if code of "python -c code" contains surrogates ........ r81251 | victor.stinner | 2010-05-17 03:26:01 +0200 (lun., 17 mai 2010) | 3 lines PyObject_Dump() encodes unicode objects to utf8 with backslashreplace (instead of strict) error handler to escape surrogates ........ r81252 | victor.stinner | 2010-05-17 10:58:51 +0200 (lun., 17 mai 2010) | 6 lines handle_system_exit() flushs files to warranty the output order PyObject_Print() writes into the C object stderr, whereas PySys_WriteStderr() writes into the Python object sys.stderr. Each object has its own buffer, so call sys.stderr.flush() and fflush(stderr). ........ r81253 | victor.stinner | 2010-05-17 11:33:42 +0200 (lun., 17 mai 2010) | 6 lines Fix refleak in internal_print() introduced by myself in r81251 _PyUnicode_AsDefaultEncodedString() uses a magical PyUnicode attribute to automatically destroy PyUnicode_EncodeUTF8() result when the unicode string is destroyed. ........
| * Merged revisions 79420 via svnmerge fromVictor Stinner2010-03-251-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r79420 | victor.stinner | 2010-03-25 13:24:38 +0100 (jeu., 25 mars 2010) | 10 lines Fix my test introduced in test_sys by r79394: Restore the orginal filesystem encoding before testing assertRaises(LookupError, sys.setfilesystemencoding, "xxx"). Unittest formats the exception, but the formatting failed because the file system was invalid (set to iso-8859-1 by the previous test). Anyway, ensure to restore the original filesystem encoding when exiting test_setfilesystemencoding() to avoid error propagation to the other tests. ........
| * Merged revisions 79393 via svnmerge fromVictor Stinner2010-03-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r79393 | victor.stinner | 2010-03-25 01:30:28 +0100 (jeu., 25 mars 2010) | 3 lines Issue #8226: sys.setfilesystemencoding() raises a LookupError if the encoding is unknown. ........
| * Merged revisions 78868-78869 via svnmerge fromVictor Stinner2010-03-211-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ................ r78868 | victor.stinner | 2010-03-12 15:20:59 +0100 (ven., 12 mars 2010) | 25 lines Merged revisions 78835-78837 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r78835 | victor.stinner | 2010-03-11 13:34:39 +0100 (jeu., 11 mars 2010) | 7 lines Issue #7774: Set sys.executable to an empty string if argv[0] has been set to an non existent program name and Python is unable to retrieve the real program name. Fix also sysconfig: if sys.executable is an empty string, use the current working directory. ........ r78836 | victor.stinner | 2010-03-11 14:27:35 +0100 (jeu., 11 mars 2010) | 4 lines Fix test_executable introduce in previous commit (r78835): Windows is able to retrieve the absolute Python path even if argv[0] has been set to a non existent program name. ........ r78837 | victor.stinner | 2010-03-11 14:46:06 +0100 (jeu., 11 mars 2010) | 3 lines Another fix to test_executable() of test_sys: set the current working to avoid the #7774 bug. ........ ................ r78869 | victor.stinner | 2010-03-12 15:27:16 +0100 (ven., 12 mars 2010) | 2 lines Oops, I loose the NEWS change in my previous backport (r78868) of r78835. ................
| * Merged revisions 75889 via svnmerge fromGeorg Brandl2009-10-271-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://svn.python.org/python/branches/py3k ................ r75889 | georg.brandl | 2009-10-28 00:00:28 +0100 (Mi, 28 Okt 2009) | 9 lines Merged revisions 75887 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r75887 | georg.brandl | 2009-10-27 23:56:09 +0100 (Di, 27 Okt 2009) | 1 line Make sure every run of test_intern() interns a new string, otherwise that test fails e.g. when some other test in test_builtin fails and it is rerun in verbose mode. ........ ................
| * Merged revisions 73715 via svnmerge fromGeorg Brandl2009-08-131-51/+51
| | | | | | | | | | | | | | | | | | | | svn+ssh://svn.python.org/python/branches/py3k ........ r73715 | benjamin.peterson | 2009-07-01 01:06:06 +0200 (Mi, 01 Jul 2009) | 1 line convert old fail* assertions to assert* ........
* | Tighten the restrictions on the test_sys test which triggers a fatal error whenBrett Cannon2011-01-251-2/+2
| | | | | | | | run with tracing turned on.
* | Skip a recursion depth check test when running under CPython and have a traceBrett Cannon2011-01-231-0/+2
| | | | | | | | | | | | | | function set. Otherwise a Python fatal error about hitting an unrecoverable recursion depth gets triggered. Closes issue #10985. Code review by Georg Brandl.
* | Update tests and whatsnew for the 'quiet' flagRaymond Hettinger2011-01-051-1/+1
| |
* | Issue #10783: Fix test_sys, pack('c', ' ') => pack('c', b' ')Victor Stinner2010-12-281-1/+1
| |
* | Issue 2690: Add support for slicing and negative indices to range objects ↵Nick Coghlan2010-12-031-2/+2
| | | | | | | | | | | | (includes precalculation and storage of the range length). Refer to the tracker issue for the language moratorium implications of this change
* | #9424: Replace deprecated assert* methods in the Python test suite.Ezio Melotti2010-11-201-7/+7
| |
* | Issue #10293: Remove obsolete field in the PyMemoryView structure,Antoine Pitrou2010-11-041-1/+1
| | | | | | | | | | unused undocumented value PyBUF_SHADOW, and strangely-looking code in PyMemoryView_GetContiguous.
* | Follow up to #9778: fix regressions on 64-bit Windows buildsAntoine Pitrou2010-10-231-1/+1
| |
* | Move test_undecodable_code() from test_sys to test_cmd_lineVictor Stinner2010-10-201-38/+0
| |
* | First (uncontroversial) part of issue 9807.Barry Warsaw2010-10-161-0/+2
| | | | | | | | | | | | | | | | | | * Expose the build flags to Python as sys.abiflags * Shared library libpythonX.Y<abiflags>.so * python-config --abiflags * Make two distutils tests that failed with --enable-shared (even before this patch) succeed. * Fix a few small style issues.
* | Issue #9308: Removed redundant coding cookies. Added tests forAlexander Belopolsky2010-10-151-1/+0
| | | | | | | | | | importing encoded modules that do not depend on specific stdlib modules being encoded in a certain way.
* | test_sys: Remove workaround #8611Victor Stinner2010-10-131-3/+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 #9992: Remove PYTHONFSENCODING environment variable.Victor Stinner2010-10-131-29/+0
| |
* | Issue #9632: Remove sys.setfilesystemencoding() function: use PYTHONFSENCODINGVictor Stinner2010-09-101-11/+0
| | | | | | | | | | | | environment variable to set the filesystem encoding at Python startup. sys.setfilesystemencoding() creates inconsistencies because it is unable to reencode all filenames in all objects.
* | Fix test_sys: set LC_ALL instead of LANGVictor Stinner2010-08-251-3/+4
| | | | | | | | | | LC_ALL is read before LANG to choose the locale encoding (LC_ALL, LANG and then LC_CTYPE: use the first non empty variable).
* | Disable test_undecodable_code() of test_sys on WindowsVictor Stinner2010-08-251-0/+6
| | | | | | | | This test is irrevelant on Windows
* | Fix test_sys for FreeBSD, Solaris and Mac OS XVictor Stinner2010-08-241-2/+15
| | | | | | | | | | | | | | _Py_char2wchar() (mbctowcs) decodes b'\xff' to '\xff' on FreeBSD, Solaris and Mac OS X, even if the locale is C (and the locale encoding is ASCII). Patch test_undecodable_code() to support this output and document the two different kinds of outputs.
* | Workaround issue #8611 in test_undecodable_code() of test_sysVictor Stinner2010-08-201-22/+22
| | | | | | | | | | Write test.support.workaroundIssue8611() function so it will be easier to remove this workaround from all tests.
* | test_undecodable_code(): set locale to CVictor Stinner2010-08-201-15/+12
| | | | | | | | | | | | | | | | | | | | The test is still failing on "x86 FreeBSD 7.2 3.x" and "sparc solaris10 gcc 3.x" buildbots. It looks like the locale encoding is able to decode b'\xff'. I suppose that it is an encoding like 'iso-8859-1'. Use C locale to set, I hope, the locale encoding to 'ascii'. Display also the encoding so if the test fails, at least I will learn the locale encoding choosen for the C locale.
* | test_main_invalid_unicode() of test_sys: print string as asciiVictor Stinner2010-08-201-1/+1
| | | | | | | | | | | | | | | | | | There are buildbot failures on "x86 FreeBSD 3.x" and "sparc solaris10 gcc 3.x". I suppose that _Py_char2wchar() doesn't fail even if the locale encoding is unable to decode the byte string, because _Py_char2wchar() has a special mode for platform without mbrtowc() (ISO C99) function. Let's check my theory by avoid error on the Python print() instruction.
* | test_main_invalid_unicode() of test_sys displays stderr on failureVictor Stinner2010-08-191-4/+3
| |
* | Ooops, finish test_sys fix: use expected variableVictor Stinner2010-08-191-1/+1
| |
* | Fix test_sys about fs encoding for Windows and Mac OS XVictor Stinner2010-08-191-17/+22
| | | | | | | | | | | | * Check fs encoding value on Windows * Ignore LANG= test on Windows and Mac OS X (fs encoding is hardcoded on these platforms)
* | test_sys: move tests at the right placeVictor Stinner2010-08-181-56/+57
| | | | | | | | filesystem encoding is not related to sys.sizeof()
* | Improve error message if the command is not decodableVictor Stinner2010-08-181-1/+4
| |
* | Issue #8622: Add PYTHONFSENCODING environment variable to override theVictor Stinner2010-08-181-8/+24
| | | | | | | | | | | | filesystem encoding. initfsencoding() displays also a better error message if get_codeset() failed.
* | Issue #9425: file system encoding is not always utf-8Victor Stinner2010-08-081-4/+1
| | | | | | | | Fix a regression introduced in test_sys by r83778.
* | Issue #9425: skip tests if a filename is not encodableVictor Stinner2010-08-071-2/+4
| |
* | Syntax cleanup.Florent Xicluna2010-07-281-3/+1
| |
* | Corrected comments on where settrace and setprofile are tested.Alexander Belopolsky2010-07-251-2/+2
| |
* | Undo inadvertant checkin.Brian Curtin2010-07-081-1/+1
| |
* | Implement #1578269. Patch by Jason R. Coombs.Brian Curtin2010-07-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* | Issue #8965: Write more tests for sys.getfilesystemencoding()Victor Stinner2010-06-111-11/+24
| |
* | Issue #8965: Add a regression test to test_sys with LANG=CVictor Stinner2010-06-111-2/+13
| |