Browse Source

Fixs tests for updated report label

Wade Simba Khadder 8 years ago
parent
commit
8b643ccdaa

+ 1
- 1
internal/driver/testdata/pprof.cpusmall.flat.addresses.tree View File

@@ -1,5 +1,5 @@
1 1
 Showing nodes accounting for 4s, 100% of 4s total
2
-Showing top 4 nodes out of 5 (cum >= 2s)
2
+Showing top 4 nodes out of 5
3 3
 ----------------------------------------------------------+-------------
4 4
       flat  flat%   sum%        cum   cum%   calls calls% + context 	 	 
5 5
 ----------------------------------------------------------+-------------

+ 1
- 2
internal/report/report.go View File

@@ -827,8 +827,7 @@ func reportLabels(rpt *Report, g *graph.Graph, origCount, droppedNodes, droppedE
827 827
 		}
828 828
 		if nodeCount > 0 && nodeCount < origCount {
829 829
 			label = append(label, fmt.Sprintf("Showing top %d nodes out of %d",
830
-				nodeCount, origCount,
831
-				rpt.formatValue(g.Nodes[len(g.Nodes)-1].Cum)))
830
+				nodeCount, origCount))
832 831
 		}
833 832
 	}
834 833
 	return label