MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_legacy_paths

Method test_legacy_paths

Lib/test/test_compileall.py:638–646  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

636 locals()['test_pep3147_paths_' + name] = f
637
638 def test_legacy_paths(self):
639 # Ensure that with the proper switch, compileall leaves legacy
640 # pyc files, and no __pycache__ directory.
641 self.assertRunOK('-b', '-q', self.pkgdir)
642 # Verify the __pycache__ directory contents.
643 self.assertFalse(os.path.exists(self.pkgdir_cachedir))
644 expected = sorted(['__init__.py', '__init__.pyc', 'bar.py',
645 'bar.pyc'])
646 self.assertEqual(sorted(os.listdir(self.pkgdir)), expected)
647
648 def test_multiple_runs(self):
649 # Bug 8527 reported that multiple calls produced empty

Callers

nothing calls this directly

Calls 6

assertRunOKMethod · 0.95
sortedFunction · 0.85
assertFalseMethod · 0.80
listdirMethod · 0.80
existsMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected