Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Lib/test/test_lazy_import/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -484,8 +484,8 @@ def my_filter(name):
sys.set_lazy_imports_filter(my_filter)
self.assertIs(sys.get_lazy_imports_filter(), my_filter)

def test_lazy_modules_attribute_is_set(self):
"""sys.lazy_modules should be a set per PEP 810."""
def test_lazy_modules_attribute_is_dict(self):
"""sys.lazy_modules should be a dict per PEP 810."""
self.assertIsInstance(sys.lazy_modules, dict)

@support.requires_subprocess()
Expand Down Expand Up @@ -966,7 +966,7 @@ def test_module_added_to_lazy_modules_on_lazy_import(self):

def test_lazy_modules_is_per_interpreter(self):
"""Each interpreter should have independent sys.lazy_modules."""
# Basic test that sys.lazy_modules exists and is a set
# Basic test that sys.lazy_modules exists and is a dict
self.assertIsInstance(sys.lazy_modules, dict)


Expand Down Expand Up @@ -1532,7 +1532,7 @@ def access_modules(idx):
self.assertEqual(result.returncode, 0, f"stdout: {result.stdout}, stderr: {result.stderr}")
self.assertIn("OK", result.stdout)

def test_concurrent_lazy_modules_set_updates(self):
def test_concurrent_lazy_modules_dict_updates(self):
"""Multiple threads creating lazy imports should safely update sys.lazy_modules."""
code = textwrap.dedent("""
import sys
Expand Down
Loading