diff --git a/Lib/test/test_selectors.py b/Lib/test/test_selectors.py index 68e2b991ec7..34edd7630dd 100644 --- a/Lib/test/test_selectors.py +++ b/Lib/test/test_selectors.py @@ -109,7 +109,7 @@ def test_unregister_after_fd_close(self): s.unregister(r) s.unregister(w) - @unittest.skipUnless(hasattr(os, 'dup2'), "need os.dup2()") + @unittest.skipUnless(os.name == 'posix', "requires posix") def test_unregister_after_fd_close_and_reuse(self): s = self.SELECTOR() self.addCleanup(s.close)