We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0a3e854 commit c8fd9f0Copy full SHA for c8fd9f0
tests/test_modutils.py
@@ -269,11 +269,18 @@ def test_std_lib(self) -> None:
269
)
270
271
def test_std_lib_found_before_same_named_package_on_path(self) -> None:
272
- sys.path.insert(0, resources.find("data"))
+ resource = resources.find("data")
273
+ sys.path.insert(0, resource)
274
self.addCleanup(sys.path.pop, 0)
275
+ sys_path = str(sys.path)
276
277
file = modutils.file_from_modpath(["copy"])
278
279
+ assert False, str(
280
+ resource,
281
+ sys_path,
282
+ file
283
+ )
284
self.assertNotIn("test", file) # tests/testdata/python3/data/copy.py
285
self.assertTrue(any(stdlib in file for stdlib in modutils.STD_LIB_DIRS))
286
0 commit comments