Commit 6502841d authored by Jason Madden's avatar Jason Madden

Don't try to run SIGCHLD test on win32

parent 2cd690c5
......@@ -19,18 +19,21 @@ def handle_sigchld(*args):
raise TypeError("This should be ignored but printed")
import signal
assert signal.getsignal(signal.SIGCHLD) == signal.SIG_DFL
signal.signal(signal.SIGCHLD, handle_sigchld)
handler = signal.getsignal(signal.SIGCHLD)
assert signal.getsignal(signal.SIGCHLD) is handle_sigchld, handler
if hasattr(signal, 'SIGCHLD'):
assert signal.getsignal(signal.SIGCHLD) == signal.SIG_DFL
signal.signal(signal.SIGCHLD, handle_sigchld)
handler = signal.getsignal(signal.SIGCHLD)
assert signal.getsignal(signal.SIGCHLD) is handle_sigchld, handler
pid = os.fork()
if not pid:
pid = os.fork()
if not pid:
# child
gevent.sleep(0.2)
sys.exit(0)
else:
else:
with gevent.Timeout(1):
while awaiting_child:
gevent.sleep(0.01)
sys.exit(0)
else:
print("No SIGCHLD, not testing")
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment