FileTreeNodeRenderer.create(context.getResources());
Tree.View<FileTreeNode> view = new Tree.View<FileTreeNode>(context.getResources());
Tree.Model<FileTreeNode> model =
new Tree.Model<FileTreeNode>(dataAdapter, nodeRenderer, context.getResources());
// An empty root directory.
DirInfoImpl mockDirInfo = DirInfoImpl.make();
mockDirInfo.setNodeType(TreeNodeInfo.DIR_TYPE);
JsoArray<FileInfo> files = JsoArray.create();
mockDirInfo.setFiles(files);
JsoArray<DirInfo> subdirs = JsoArray.create();
mockDirInfo.setSubDirectories(subdirs);
mockDirInfo.setName("");
mockDirInfo.setIsComplete(true);
FileTreeNode root = FileTreeNode.transform(mockDirInfo);
model.setRoot(root);
tree = new Tree<FileTreeNode>(view, model);
// Create all the other objects we need, or mocks for them...