# HG changeset patch # User Matt Harbison # Date 1730760150 18000 # Node ID 3ba998d7fc7785fcdc9c1be76f9e4e845e3dc463 # Parent 891f6d56f3dbd49226424b78d275d0133b705fb9 tests: treat `select` as a built-in module on Windows This fixes: --- C:/Users/Matt/hg/tests/test-check-module-imports.t +++ C:/Users/Matt/hg/tests/test-check-module-imports.t.err @@ -43,3 +43,15 @@ > -X tests/test-verify-repo-operations.py \ > -X tests/test-extension.t \ > | sed 's-\\-/-g' | "$PYTHON" "$import_checker" - + hgext/zeroconf/Zeroconf.py:86: stdlib import "socket" follows local import: select\r (esc) + hgext/zeroconf/Zeroconf.py:87: stdlib import "struct" follows local import: select\r (esc) + hgext/zeroconf/Zeroconf.py:88: stdlib import "threading" follows local import: select\r (esc) + hgext/zeroconf/Zeroconf.py:89: stdlib import "time" follows local import: select\r (esc) + hgext/zeroconf/Zeroconf.py:90: stdlib import "traceback" follows local import: select\r (esc) + mercurial/posix.py:18: stdlib import "stat" follows local import: select\r (esc) + mercurial/posix.py:19: stdlib import "sys" follows local import: select\r (esc) + mercurial/posix.py:20: stdlib import "tempfile" follows local import: select\r (esc) + mercurial/posix.py:21: stdlib import "typing" follows local import: select\r (esc) + tests/tinyproxy.py:19: stdlib import "socket" follows local import: select\r (esc) + tests/tinyproxy.py:20: stdlib import "sys" follows local import: select\r (esc) + [1] ERROR: test-check-module-imports.t output changed diff -r 891f6d56f3db -r 3ba998d7fc77 contrib/import-checker.py --- a/contrib/import-checker.py Thu Oct 31 17:24:18 2024 -0400 +++ b/contrib/import-checker.py Mon Nov 04 17:42:30 2024 -0500 @@ -231,7 +231,7 @@ yield 'importlib.machinery' # python3 only yield 'importlib.util' # python3 only yield 'packaging.version' - for m in 'fcntl', 'grp', 'pwd', 'termios': # Unix only + for m in 'fcntl', 'grp', 'pwd', 'select', 'termios': # Unix only yield m for m in 'cPickle', 'datetime': # in Python (not C) on PyPy yield m