Added doctests to api_tree_node