Kaydet (Commit) 632df993 authored tarafından Florent Xicluna's avatar Florent Xicluna

Skip test_send_signal, test_kill, test_terminate on win32 platforms, for 2.7a4 release.

üst 985478db
...@@ -768,24 +768,30 @@ class Win32ProcessTestCase(unittest.TestCase): ...@@ -768,24 +768,30 @@ class Win32ProcessTestCase(unittest.TestCase):
' -c "import sys; sys.exit(47)"') ' -c "import sys; sys.exit(47)"')
self.assertEqual(rc, 47) self.assertEqual(rc, 47)
@unittest.skip("It fails on some win32 platforms. See issue #2777")
def test_send_signal(self): def test_send_signal(self):
# Do not inherit file handles from the parent. # Redirect the stdin file handle.
# It should fix failure on some platforms. # It should fix failure on some win32 platforms.
p = subprocess.Popen([sys.executable, "-c", "input()"], close_fds=True) p = subprocess.Popen([sys.executable, "-c", "input()"],
stdin=subprocess.PIPE)
self.assertIs(p.poll(), None) self.assertIs(p.poll(), None)
p.send_signal(signal.SIGTERM) p.send_signal(signal.SIGTERM)
self.assertNotEqual(p.wait(), 0) self.assertNotEqual(p.wait(), 0)
@unittest.skip("It fails on some win32 platforms. See issue #2777")
def test_kill(self): def test_kill(self):
p = subprocess.Popen([sys.executable, "-c", "input()"], close_fds=True) p = subprocess.Popen([sys.executable, "-c", "input()"],
stdin=subprocess.PIPE)
self.assertIs(p.poll(), None) self.assertIs(p.poll(), None)
p.kill() p.kill()
self.assertNotEqual(p.wait(), 0) self.assertNotEqual(p.wait(), 0)
@unittest.skip("It fails on some win32 platforms. See issue #2777")
def test_terminate(self): def test_terminate(self):
p = subprocess.Popen([sys.executable, "-c", "input()"], close_fds=True) p = subprocess.Popen([sys.executable, "-c", "input()"],
stdin=subprocess.PIPE)
self.assertIs(p.poll(), None) self.assertIs(p.poll(), None)
p.terminate() p.terminate()
......
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