mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
[BE][Ez]: Use interned hardcoded string FURB156 (#138330)
Uses string constants from string module. Pull Request resolved: https://github.com/pytorch/pytorch/pull/138330 Approved by: https://github.com/albanD
This commit is contained in:
committed by
PyTorch MergeBot
parent
9c2a80322a
commit
195d0a666b
@ -30,6 +30,7 @@ from torch.testing._internal.common_dtype import all_types_and_complex_and, floa
|
||||
from torch.testing._internal.common_modules import modules, module_db, ModuleInfo
|
||||
from torch.testing._internal.opinfo.core import SampleInput, DecorateInfo, OpInfo
|
||||
import operator
|
||||
import string
|
||||
|
||||
# For testing TestCase methods and torch.testing functions
|
||||
class TestTesting(TestCase):
|
||||
@ -2299,7 +2300,7 @@ class TestImports(TestCase):
|
||||
# Calling logging.basicConfig, among other things, modifies the global
|
||||
# logging state. It is not OK to modify the global logging state on
|
||||
# `import torch` (or other submodules we own) because users do not expect it.
|
||||
expected = 'abcdefghijklmnopqrstuvwxyz'
|
||||
expected = string.ascii_lowercase
|
||||
commands = [
|
||||
'import logging',
|
||||
f'import {path}',
|
||||
|
Reference in New Issue
Block a user