Skip to content

Commit f108976

Browse files
authored
[3.11] gh-111881: Use lazy import in test.support (#111885) (#111890) (#111902)
[3.12] gh-111881: Use lazy import in test.support (#111885) (#111890) gh-111881: Use lazy import in test.support (#111885) * Import lazily getpass in test.support Backport to 3.11: test.support.os_helper is unchanged. (cherry picked from commit 0372e3b) (cherry picked from commit e983ca8)
1 parent 63205e5 commit f108976

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/test/support/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
import contextlib
77
import dataclasses
88
import functools
9-
import getpass
109
import os
1110
import re
1211
import stat
@@ -380,6 +379,7 @@ def wrapper(*args, **kw):
380379

381380
def skip_if_buildbot(reason=None):
382381
"""Decorator raising SkipTest if running on a buildbot."""
382+
import getpass
383383
if not reason:
384384
reason = 'not suitable for buildbots'
385385
try:

0 commit comments

Comments
 (0)