]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-154289: Fix test_socket.testGetServBy on DragonFly (GH-154290)
authorSerhiy Storchaka <storchaka@gmail.com>
Mon, 20 Jul 2026 19:25:33 +0000 (22:25 +0300)
committerGitHub <noreply@github.com>
Mon, 20 Jul 2026 19:25:33 +0000 (19:25 +0000)
DragonFly lists "echo 4/ddp" before "echo 7/tcp" in /etc/services, like
FreeBSD, so avoid the "echo" service there too.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Lib/test/test_socket.py

index 99f9e746c854e32f9ed14b4cc15c3ad04c72f8a9..a234d6b37ff37976d711c65f55c1891e4353310c 100644 (file)
@@ -1302,7 +1302,8 @@ class GeneralModuleTests(unittest.TestCase):
         # protocol, at least for modern Linuxes.
         if (
             sys.platform.startswith(
-                ('linux', 'android', 'freebsd', 'netbsd', 'gnukfreebsd'))
+                ('linux', 'android', 'freebsd', 'dragonfly', 'netbsd',
+                 'gnukfreebsd'))
             or is_apple
         ):
             # avoid the 'echo' service on this platform, as there is an