Skip to content

Commit

Permalink
Python itself won't actually catch SIGINT on Windows (python WONTFIX …
Browse files Browse the repository at this point in the history
…issue 18040), so we just won't try on windows.
  • Loading branch information
CleanCut committed Sep 2, 2014
1 parent 0b7536b commit 37a2c68
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions green/runner.py
Expand Up @@ -29,6 +29,8 @@ def run(suite, stream, args):
stream, args.verbose, html=args.html,
termcolor=args.termcolor)

# Note: Catching SIGINT isn't supported by Python on windows (python
# "WONTFIX" issue 18040)
installHandler()
registerResult(result)

Expand Down
5 changes: 5 additions & 0 deletions green/test/test_runner.py
@@ -1,6 +1,7 @@
from __future__ import unicode_literals
import copy
import os
import platform
import shutil
import signal
import sys
Expand Down Expand Up @@ -37,6 +38,8 @@ def test_catchSIGINT(self):
"""
run() can catch SIGINT.
"""
if platform.system() == 'Windows':
self.skipTest('This test is for posix-specific behavior.')
# Mock the list of TestResult instances that should be stopped,
# otherwise the actual TestResult that is running this test will be
# told to stop when we send SIGINT
Expand Down Expand Up @@ -142,6 +145,8 @@ def test_catchSubprocessSIGINT(self):
"""
run() can catch SIGINT while running a subprocess.
"""
if platform.system() == 'Windows':
self.skipTest('This test is for posix-specific behavior.')
# Mock the list of TestResult instances that should be stopped,
# otherwise the actual TestResult that is running this test will be
# told to stop when we send SIGINT
Expand Down

0 comments on commit 37a2c68

Please sign in to comment.