public void LoadRecursiveLoadsCompleateSubtree() { var treeView = new TestTreeView(); var treeLoader = new FavoriteTreeListLoader(treeView, this.Persistence); treeLoader.LoadRootNodes(); // now we have 7 including Dummy nodes var rootNodes = new TreeListNodes(treeView.Nodes); treeLoader.LoadGroupNodesRecursive(rootNodes); int allLoadedCount = treeView.GetNodeCount(true); // or assert: treeView.Nodes[1].Nodes[0].Nodes[0].Name = "FavoriteA" // Dummy are replaced, and also Favorite nodes are included Assert.AreEqual(8, allLoadedCount, "Loading recursive subtree should load all nodes without expanding them"); treeView.Dispose(); }