MCPcopy Create free account
hub / github.com/RustPython/RustPython / test_move_into

Method test_move_into

Lib/test/test_pathlib/test_pathlib.py:1771–1780  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1769 self.test_move_dangling_symlink()
1770
1771 def test_move_into(self):
1772 base = self.cls(self.base)
1773 source = base / 'fileA'
1774 source_text = source.read_text()
1775 target_dir = base / 'dirA'
1776 result = source.move_into(target_dir)
1777 self.assertEqual(result, target_dir / 'fileA')
1778 self.assertFalse(source.exists())
1779 self.assertTrue(result.exists())
1780 self.assertEqual(source_text, result.read_text())
1781
1782 @patch_replace
1783 def test_move_into_other_os(self):

Callers 1

Calls 7

move_intoMethod · 0.80
assertFalseMethod · 0.80
assertTrueMethod · 0.80
clsMethod · 0.45
read_textMethod · 0.45
assertEqualMethod · 0.45
existsMethod · 0.45

Tested by

no test coverage detected