summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_signal.py
Commit message (Collapse)AuthorAgeFilesLines
* Add extra information to a test_signal failure message to aid diagnosis of ↵Mark Dickinson2009-11-091-1/+3
| | | | buildbot failure.
* Issue #7042: Use a better mechanism for testing timers in test_signal.Mark Dickinson2009-10-311-2/+10
|
* Issue #7042: Fix test_signal failure on OS X 10.6 64-bit buildsMark Dickinson2009-10-041-0/+2
| | | | | (and also, with luck, on the x86 FreeBSD buildbot), by making sure that some user time is used in test_itimer_virtual.
* convert usage of fail* to assert*Benjamin Peterson2009-06-301-3/+3
|
* #6276: Remove usage of nested() in favor of new with statement with multiple ↵Georg Brandl2009-06-181-3/+3
| | | | managers.
* remove test_support.TestSkipped and just use unittest.SkipTestBenjamin Peterson2009-03-261-1/+1
|
* Add enough debugging information to diagnose failures where theJeffrey Yasskin2008-04-061-5/+14
| | | | | | | | HandlerBException is ignored, and fix one such problem, where it was thrown during the __del__ method of the previous Popen object. We may want to find a better way of printing verbose information so it's not spammy when the test passes.
* Oops again. EINTR is in errno, not signal.Jeffrey Yasskin2008-04-041-1/+1
|
* Doh! os.read() raises an OSError, not an IOError when it's interrupted.Jeffrey Yasskin2008-04-041-2/+5
| | | | | And fix some flakiness in test_itimer_prof, which could detect that the timer had reached 0 before the signal arrived announcing that fact.
* Try to make test_signal less flaky. I still see some flakiness inJeffrey Yasskin2008-04-021-6/+24
| | | | test_itimer_prof.
* Try to get this test to be more stable:Neal Norwitz2008-03-251-4/+15
| | | | | | | | * disable gc during the test run because we are spawning objects and there was an exception when calling Popen.__del__ * Always set an alarm handler so the process doesn't exit if the test fails (should probably add assertions on the value of hndl_called in more places) * Using a negative time causes Linux to treat it as zero, so disable that test.
* Patch #2240: Implement signal.setitimer and signal.getitimer.Martin v. Löwis2008-03-241-1/+85
|
* Try to fix test_signal on FreeBSD. I'm assuming that os.kill is failing toJeffrey Yasskin2008-03-211-19/+7
| | | | raise a signal, but switching to subprocess makes the code cleaner anyway.
* Try to fix test_signal breakages on Linux due to r61687. It appears that atJeffrey Yasskin2008-03-211-2/+4
| | | | | | least two of the linux build bots aren't leaving zombie processes around for os.waitpid to wait for, causing ECHILD errors. This would be a symptom of a bug somewhere, but probably not in signal itself.
* Speed up test_signal from ~24s to 4s by avoiding nearly all of the sleep calls.Jeffrey Yasskin2008-03-211-121/+129
|
* Windows fix for signal test - skip it earlierChristian Heimes2008-02-281-5/+6
|
* Issue 1089358. Adds the siginterrupt() function, that is just aFacundo Batista2008-02-231-2/+46
| | | | | | wrapper around the system call with the same name. Also added test cases, doc changes and NEWS entry. Thanks Jason and Ralf Schmitt.
* Patch #1583 by Adam Olsen.Guido van Rossum2007-12-191-1/+48
| | | | | | | This adds signal.set_wakeup_fd(fd) which sets a file descriptor to which a zero byte will be written whenever a C exception handler runs. I added a simple C API as well, PySignal_SetWakeupFd(fd).
* Patch #1008: port test_signal to unittest.Georg Brandl2007-08-241-161/+171
|
* Ah, fudge. One of the prints here actually "shouldn't be"Tim Peters2006-08-121-2/+1
| | | | | | | | | protected by "if verbose:", which caused the test to fail on all non-Windows boxes. Note that I deliberately didn't convert this to unittest yet, because I expect it would be even harder to debug this on Tru64 after conversion.
* test_signal: Signal handling on the Tru64 buildbotTim Peters2006-08-121-64/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | appears to be utterly insane. Plug some theoretical insecurities in the test script: - Verify that the SIGALRM handler was actually installed. - Don't call alarm() before the handler is installed. - Move everything that can fail inside the try/finally, so the test cleans up after itself more often. - Try sending all the expected signals in force_test_exit(), not just SIGALRM. Since that was fixed to actually send SIGALRM (instead of invisibly dying with an AttributeError), we've seen that sending SIGALRM alone does not stop this from hanging. - Move the "kill the child" business into the finally clause, so the child doesn't survive test failure to send SIGALRM to other tests later (there are also baffling SIGALRM-related failures in test_socket). - Cancel the alarm in the finally clause -- if the test dies early, we again don't want SIGALRM showing up to confuse a later test. Alas, this still relies on timing luck wrt the spawned script that sends the test signals, but it's hard to see how waiting for seconds can so often be so unlucky. test_threadedsignals: curiously, this test never fails on Tru64, but doesn't normally signal SIGALRM. Anyway, fixed an obvious (but probably inconsequential) logic error.
* force_test_exit(): This has been completely ineffectiveTim Peters2006-08-111-1/+5
| | | | | | | at stopping test_signal from hanging forever on the Tru64 buildbot. That could be because there's no such thing as signal.SIGALARM. Changed to the idiotic (but standard) signal.SIGALRM instead, and added some more debug output.
* Let us know when there was a problem and the child had to kill the parentNeal Norwitz2006-08-021-0/+1
|
* Try to prevent hangs on Tru64/Alpha buildbot. I'm not certain this will helpNeal Norwitz2006-07-301-1/+37
| | | | and may need to be reverted if it causes problems.
* Verify that the signal handlers were really calledNeal Norwitz2006-07-301-0/+12
|
* Test getsignal() and some error conditionsNeal Norwitz2006-01-231-1/+23
|
* Let's not use string exceptions any more.Armin Rigo2004-08-071-1/+2
|
* lightly modified version of my patchMichael W. Hudson2004-06-111-24/+31
| | | | | | [ 971323 ] make test_signal less annoying after some comments on IRC from a highly opinionated australian who wishes to remain anonymous.
* Whitespace normalization.Tim Peters2003-04-241-1/+0
|
* Take out my (long since disabled) POSIX signal mask handling code.Michael W. Hudson2003-03-131-61/+0
| | | | | I'm not going to have the time or energy to get this working x-platform -- anyone who does is welcome to the code!
* Get rid of relative imports in all unittests. Now anything thatBarry Warsaw2002-07-231-1/+1
| | | | | | | | | | | imports e.g. test_support must do so using an absolute package name such as "import test.test_support" or "from test import test_support". This also updates the README in Lib/test, and gets rid of the duplicate data dirctory in Lib/test/data (replaced by Lib/email/test/data). Now Tim and Jack can have at it. :)
* Whitespace normalization.Tim Peters2002-07-161-1/+0
|
* This is patchMichael W. Hudson2002-05-271-3/+65
| | | | | | | [ 559250 ] more POSIX signal stuff Adds support (and docs and tests and autoconfery) for posix signal mask handling -- sigpending, sigprocmask and sigsuspend.
* SF patch #474590 -- RISC OS supportGuido van Rossum2001-10-241-2/+2
|
* a bold attempt to fix things broken by MAL's verify patch: importFredrik Lundh2001-01-171-1/+1
| | | | 'verify' iff it's used by a test module...
* This patch removes all uses of "assert" in the regression test suiteMarc-André Lemburg2001-01-171-1/+1
| | | | | | | and replaces them with a new API verify(). As a result the regression suite will also perform its tests in optimization mode. Written by Marc-Andre Lemburg. Copyright assigned to Guido van Rossum.
* Make reindent.py happy (convert everything to 4-space indents!).Fred Drake2000-10-231-31/+31
|
* Raise 'TestSkipped' (from the test_support) module rather than 'ImportError'Thomas Wouters2000-08-041-2/+2
| | | | | to signify a test that should be marked as 'skipped' rather than 'failed'. Also 'document' it, in README.
* os2 patch by Jeff RushGuido van Rossum1997-11-221-3/+2
|
* Soft failure for Win32 platform.Guido van Rossum1997-04-161-0/+4
|
* test_rotor.py: New test of the rotor module.Barry Warsaw1996-12-231-10/+23
| | | | | | | test_*: converted to the new test harness. GvR note! test_signal.py works interatively (i.e. when verbose=1) but does not work inside the test harness. It must be a timing issue, but I haven't figured it out yet.
* test signal moduleGuido van Rossum1995-03-161-0/+50