MCPcopy Index your code
hub / github.com/python/cpython / find_spec

Method find_spec

Lib/test/test_pkgutil.py:372–377  ·  view source on GitHub ↗
(self, fullname, path=None, target=None)

Source from the content-addressed store, hash-verified

370
371 class MyTestImporter(object):
372 def find_spec(self, fullname, path=None, target=None):
373 loader = PkgutilPEP302Tests.MyTestLoader()
374 return spec_from_file_location(fullname,
375 '<%s>' % loader.__class__.__name__,
376 loader=loader,
377 submodule_search_locations=[])
378
379 def setUp(self):
380 sys.meta_path.insert(0, self.MyTestImporter())

Callers 1

test_iter_importersMethod · 0.45

Calls 1

spec_from_file_locationFunction · 0.85

Tested by

no test coverage detected