diff options
| author | Jeff Quast <contact@jeffquast.com> | 2014-11-23 15:18:58 -0800 |
|---|---|---|
| committer | Jeff Quast <contact@jeffquast.com> | 2014-11-23 15:18:58 -0800 |
| commit | 79d856b598c1755e3f6cf8d7dd5ce8d19afa02bc (patch) | |
| tree | 9f2be51c628bbbda21da99694290dbd54b80125c | |
| parent | 2c5192daff1d45b4bb3d0235abf9c54a1b90c691 (diff) | |
| download | pexpect-propose-more-reliable-terminate.tar.gz | |
add SIGCONT and use select, not time.sleeppropose-more-reliable-terminate
| -rwxr-xr-x | tests/needs_kill.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/needs_kill.py b/tests/needs_kill.py index 9f44603..596b60a 100755 --- a/tests/needs_kill.py +++ b/tests/needs_kill.py @@ -1,12 +1,14 @@ #!/usr/bin/env python """This script can only be killed by SIGKILL.""" import signal -import time +import select # Ignore interrupt, hangup and continue signals - only SIGKILL will work signal.signal(signal.SIGINT, signal.SIG_IGN) signal.signal(signal.SIGHUP, signal.SIG_IGN) +signal.signal(signal.SIGCONT, signal.SIG_IGN) signal.signal(signal.SIGTERM, signal.SIG_IGN) +select.select([], [], [], 1) print('READY') -time.sleep(60) +select.select([], [], [], 60) |
