From: Gregory P. Smith Date: Mon, 1 Mar 2010 06:01:02 +0000 (+0000) Subject: Fix test to be skipped on windows. X-Git-Tag: v2.7a4~79 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7512a9068d372c58ada8f88296217633d3377092;p=python Fix test to be skipped on windows. --- diff --git a/Lib/test/test_thread.py b/Lib/test/test_thread.py index 4e707e5a13..b476317d5e 100644 --- a/Lib/test/test_thread.py +++ b/Lib/test/test_thread.py @@ -201,11 +201,9 @@ class TestForkInThread(unittest.TestCase): def setUp(self): self.read_fd, self.write_fd = os.pipe() + @unittest.skipIf(sys.platform.startswith('win'), + "This test is only appropriate for POSIX-like systems.") def test_forkinthread(self): - if sys.platform.startswith('win'): - from test.test_support import TestSkipped - raise TestSkipped("This test is only appropriate for " - "POSIX-like systems.") def thread1(): try: pid = os.fork() # fork in a thread