summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_sys.py
Commit message (Collapse)AuthorAgeFilesLines
* current_frames_with_threads(): There's actually no wayTim Peters2006-07-251-3/+4
| | | | | | | | | | | to guess /which/ line the spawned thread is in at the time sys._current_frames() is called: we know it finished enter_g.set(), but can't know whether the instruction counter has advanced to the following leave_g.wait(). The latter is overwhelming most likely, but not guaranteed, and I see that the "x86 Ubuntu dapper (icc) trunk" buildbot found it on the other line once. Changed the test so it passes in either case.
* SF bug 1524317: configure --without-threads fails to buildTim Peters2006-07-191-0/+22
| | | | | | | | | | | | | | | | | | Moved the code for _PyThread_CurrentFrames() up, so it's no longer in a huge "#ifdef WITH_THREAD" block (I didn't realize it /was/ in one). Changed test_sys's test_current_frames() so it passes with or without thread supported compiled in. Note that test_sys fails when Python is compiled without threads, but for an unrelated reason (the old test_exit() fails with an indirect ImportError on the `thread` module). There are also other unrelated compilation failures without threads, in extension modules (like ctypes); at least the core compiles again. Do we really support --without-threads? If so, there are several problems remaining.
* After approval from Anthony, merge the tim-current_framesTim Peters2006-07-101-0/+61
| | | | | | branch into the trunk. This adds a new sys._current_frames() function, which returns a dict mapping thread id to topmost thread stack frame.
* Add test case for #43581.Martin v. Löwis2006-04-031-0/+5
|
* Disable a few other tests, that can't work if Python is compiled withoutWalter Dörwald2005-08-031-1/+2
| | | | Unicode support.
* Whitespace normalization.Tim Peters2005-02-151-2/+2
|
* Test that SystemExits are handled properly by the exit machinery. IMichael W. Hudson2005-02-151-0/+12
| | | | | broke the "raise SystemExit(46)" case when doing new-style exceptions, but I'd much rather have found out here than in test_tempfile (growl).
* New function sys.getcheckinterval(), to complement setcheckinterval().Tim Peters2003-07-061-2/+4
|
* Combine the functionality of test_support.run_unittest()Walter Dörwald2003-05-011-3/+1
| | | | | | | | | | and test_support.run_classtests() into run_unittest() and use it wherever possible. Also don't use "from test.test_support import ...", but "from test import test_support" in a few spots. From SF patch #662807.
* Reindent the new code properly.Guido van Rossum2003-03-011-22/+22
|
* - New function sys.exc_clear() clears the current exception. This isGuido van Rossum2003-03-011-0/+44
| | | | | | rarely needed, but can sometimes be useful to release objects referenced by the traceback held in sys.exc_info()[2]. (SF patch #693195.) Thanks to Kevin Jacobs!
* Whitespace normalization.Tim Peters2003-02-191-10/+10
|
* Fix SF bug #688424, 64-bit test problemsNeal Norwitz2003-02-181-1/+1
|
* Fix typo.Walter Dörwald2003-02-031-1/+1
|
* Add a new test script that tests various features of the sysWalter Dörwald2003-02-031-0/+211
module. This increases code coverage of Python/sysmodule.c from 68% to 77% (on Linux). The script doesn't exercise the error branch that handles an evil or lost sys.excepthook in Python/pythonrun.c::PyErr_PrintEx(). Also this script might not work on Jython in its current form. From SF patch #662807.