public static TreePath findTreePathToText(JTree tree, String text) {
		TreeModel tm = tree.getModel();
		TreeNode rootNode = (TreeNode) tm.getRoot();
		TreePath rootPath = new TreePath(rootNode);
		return findPathToText(tree, rootPath, text);
	}
Finds the path of a tree node in the indicated tree with the specified
text. The matching tree node is determined by comparing the specified
text with the string returned by the tree node's toString() method. <br>
Note: This method affects the expansion state of the tree. It will expand
nodes starting at the root until a match is found or all of the tree is
checked.

@param tree the tree
@param text the tree node's text
@return the tree path
Ghidra/Framework/Gui/src/main/java/generic/test/AbstractGuiTest.java