]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-149879: Fix test_httpservers on Cygwin (#150417)
authorVictor Stinner <vstinner@python.org>
Mon, 25 May 2026 19:50:35 +0000 (21:50 +0200)
committerGitHub <noreply@github.com>
Mon, 25 May 2026 19:50:35 +0000 (19:50 +0000)
Lib/test/test_httpservers.py

index 574529c70741d8f6d546567dd36b56a32a7685fc..d4ae032610a91e23c42975840b8e8edb58aa2f6b 100644 (file)
@@ -824,7 +824,7 @@ class SimpleHTTPServerTestCase(BaseTestCase):
 
         # chmod() doesn't work as expected on Windows, and filesystem
         # permissions are ignored by root on Unix.
-        if os.name == 'posix' and os.geteuid() != 0:
+        if os.name == 'posix' and os.geteuid() != 0 and sys.platform != 'cygwin':
             os.chmod(self.tempdir, 0)
             try:
                 response = self.request(self.base_url + '/')