In unit tests, check counters

This commit is contained in:
Bryan Boreham
2020-03-10 11:30:25 +00:00
parent e6eaf11fb6
commit 1ce1ecad7c
2 changed files with 23 additions and 2 deletions

View File

@@ -22,9 +22,11 @@ func PruneNode(node report.Node) report.Node {
node.Children.ForEach(func(child report.Node) {
prunedChildren = prunedChildren.Add(PruneNode(child))
})
return report.MakeNode(
prunedNode := report.MakeNode(
node.ID).
WithTopology(node.Topology).
WithAdjacent(node.Adjacency...).
WithChildren(prunedChildren)
prunedNode.Counters = node.Counters
return prunedNode
}