code: def test_node_set_parent():
      """Test assignment of parent"""
      parent = TreeNode("test")
      child = TreeNode("test")
  
      child.set_parent(parent)
  
      assert child.parent is parent
  
      assert parent.children[0] is child
  
imports: from orion.core.utils.tree import DepthFirstTraversal, PreOrderTraversal, TreeNode, flattened
label_desc: Use image node_id 4 for calling a global function with example usage: test_node_set_parent() without return types