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

Method test_copy_file

Lib/test/test_pathlib/test_copy.py:23–30  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

21 self.target_ground.teardown(self.target_root)
22
23 def test_copy_file(self):
24 source = self.source_root / 'fileA'
25 target = self.target_root / 'copyA'
26 result = source.copy(target)
27 self.assertEqual(result, target)
28 self.assertTrue(self.target_ground.isfile(target))
29 self.assertEqual(self.source_ground.readbytes(source),
30 self.target_ground.readbytes(result))
31
32 def test_copy_file_empty(self):
33 source = self.source_root / 'empty'

Callers

nothing calls this directly

Calls 5

assertTrueMethod · 0.80
copyMethod · 0.45
assertEqualMethod · 0.45
isfileMethod · 0.45
readbytesMethod · 0.45

Tested by

no test coverage detected