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

Method test_copy_file_empty

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

Source from the content-addressed store, hash-verified

30 self.target_ground.readbytes(result))
31
32 def test_copy_file_empty(self):
33 source = self.source_root / 'empty'
34 target = self.target_root / 'copyA'
35 self.source_ground.create_file(source, b'')
36 result = source.copy(target)
37 self.assertEqual(result, target)
38 self.assertTrue(self.target_ground.isfile(target))
39 self.assertEqual(self.target_ground.readbytes(result), b'')
40
41 def test_copy_file_to_existing_file(self):
42 source = self.source_root / 'fileA'

Callers

nothing calls this directly

Calls 6

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

Tested by

no test coverage detected