test for tree