Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit3ceb4b8

Browse files
authored
gh-84623: Remove unused imports in tests (#93772)
1 parent65ff27c commit3ceb4b8

File tree

52 files changed

+8
-65
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+8
-65
lines changed

‎Lib/distutils/tests/test_bdist.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
"""Tests for distutils.command.bdist."""
2-
importos
32
importunittest
43
fromtest.supportimportrun_unittest
54

‎Lib/distutils/tests/test_sysconfig.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
fromdistutils.testsimportsupport
1313
fromtest.supportimportrun_unittest,swap_item,requires_subprocess,is_wasi
1414
fromtest.support.os_helperimportTESTFN
15-
fromtest.support.warnings_helperimportcheck_warnings
1615

1716

1817
classSysconfigTestCase(support.EnvironGuard,unittest.TestCase):

‎Lib/lib2to3/tests/test_all_fixers.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
# Python imports
99
importos.path
10-
importsys
1110
importtest.support
1211
importunittest
1312

‎Lib/test/datetimetester.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
importbisect
88
importcopy
99
importdecimal
10-
importfunctools
1110
importsys
1211
importos
1312
importpickle

‎Lib/test/libregrtest/setup.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ def _adjust_resource_limits():
141141
"""Adjust the system resource limits (ulimit) if needed."""
142142
try:
143143
importresource
144-
fromresourceimportRLIMIT_NOFILE,RLIM_INFINITY
144+
fromresourceimportRLIMIT_NOFILE
145145
exceptImportError:
146146
return
147147
fd_limit,max_fds=resource.getrlimit(RLIMIT_NOFILE)

‎Lib/test/list_tests.py‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,9 @@
33
"""
44

55
importsys
6-
importos
76
fromfunctoolsimportcmp_to_key
87

9-
fromtestimportsupport,seq_tests
8+
fromtestimportseq_tests
109
fromtest.supportimportALWAYS_EQ,NEVER_EQ
1110

1211

‎Lib/test/lock_tests.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
Various tests for synchronization primitives.
33
"""
44

5-
importos
65
importgc
76
importsys
87
importtime

‎Lib/test/test_asyncio/test_events.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
importasyncio
3030
fromasyncioimportcoroutines
3131
fromasyncioimportevents
32-
fromasyncioimportproactor_events
3332
fromasyncioimportselector_events
3433
fromtest.test_asyncioimportutilsastest_utils
3534
fromtestimportsupport

‎Lib/test/test_asyncio/test_runners.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import_thread
22
importasyncio
33
importcontextvars
4-
importgc
54
importre
65
importsignal
76
importthreading

‎Lib/test/test_asyncio/test_sock_lowlevel.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
fromasyncioimportproactor_events
77
fromitertoolsimportcycle,islice
8-
fromunittest.mockimportpatch,Mock
8+
fromunittest.mockimportMock
99
fromtest.test_asyncioimportutilsastest_utils
1010
fromtestimportsupport
1111
fromtest.supportimportsocket_helper

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp