private DataType getTypeFromTree(String name) {
		DataTypeArchiveGTree gTree = provider.getGTree();
		GTreeNode rootNode = gTree.getViewRoot();
		Iterator<GTreeNode> it = rootNode.iterator(true);
		for (GTreeNode node : CollectionUtils.asIterable(it)) {
			if (!(node instanceof DataTypeNode)) {
				continue;
			}
			DataTypeNode dtNode = (DataTypeNode) node;
			DataType dt = dtNode.getDataType();
			String dtName = dt.getName();
			if (dtName.equals(name)) {
				return dt;
			}
		}
		return null;
	}
Tests for managing categories through the data manager plugin and tests for
actions being enabled when a node is selected.
Ghidra/Features/Base/src/test.slow/java/ghidra/app/plugin/core/datamgr/DataTypeManagerPluginTest.java