MCPcopy Create free account
hub / github.com/PyTables/PyTables / test13d_copyGroupRecursive

Method test13d_copyGroupRecursive

tables/tests/test_basics.py:905–922  ·  view source on GitHub ↗

Recursively copying a group.

(self)

Source from the content-addressed store, hash-verified

903 self.assertIs(new_node, dstNode)
904
905 def test13d_copyGroupRecursive(self):
906 """Recursively copying a group."""
907
908 self._reopen(mode="r+", node_cache_slots=self.node_cache_slots)
909
910 # agroup => agroup2/
911 new_node = self.h5file.copy_node(
912 self.h5file.root.agroup, self.h5file.root.agroup2, recursive=True
913 )
914 dstNode = self.h5file.root.agroup2.agroup
915
916 self.assertIs(new_node, dstNode)
917 dstChild1 = dstNode.anarray1
918 self.assertIsNotNone(dstChild1)
919 dstChild2 = dstNode.anarray2
920 self.assertIsNotNone(dstChild2)
921 dstChild3 = dstNode.agroup3
922 self.assertIsNotNone(dstChild3)
923
924 def test13e_copyRootRecursive(self):
925 """Recursively copying the root group into the root of another file."""

Callers

nothing calls this directly

Calls 2

copy_nodeMethod · 0.80
_reopenMethod · 0.45

Tested by

no test coverage detected