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

Method check_hardlinks

Lib/test/test_compileall.py:1053–1060  ·  view source on GitHub ↗
(self, script, docstring=False, assertion=False)

Source from the content-addressed store, hash-verified

1051 self.assertFalse(is_hardlink(pycs[1], pycs[2]))
1052
1053 def check_hardlinks(self, script, docstring=False, assertion=False):
1054 pycs = get_pycs(script)
1055 self.assertEqual(is_hardlink(pycs[0], pycs[1]),
1056 not assertion)
1057 self.assertEqual(is_hardlink(pycs[0], pycs[2]),
1058 not assertion and not docstring)
1059 self.assertEqual(is_hardlink(pycs[1], pycs[2]),
1060 not docstring)
1061
1062 def test_hardlink(self):
1063 # Test deduplication on all combinations

Callers 3

test_hardlinkMethod · 0.95
test_recompilationMethod · 0.95
test_importMethod · 0.95

Calls 3

get_pycsFunction · 0.85
is_hardlinkFunction · 0.85
assertEqualMethod · 0.45

Tested by

no test coverage detected