MCPcopy Create free account
hub / github.com/google/pprof / checkUnitText

Function checkUnitText

browsertests/testdata/testflame.js:113–118  ·  view source on GitHub ↗
(unit, v, expect)

Source from the content-addressed store, hash-verified

111
112 test.run("Units", function() {
113 function checkUnitText(unit, v, expect) {
114 const result = pprofUnitText(v, unit);
115 if (result != expect) {
116 test.err("bad text for", v, unit, ":", result, "expecting:", expect);
117 }
118 }
119
120 // Time units, plus logic tests.
121 checkUnitText("s", 0.51e-9, "0.51ns");

Callers 1

TestFlameFunction · 0.85

Calls 2

pprofUnitTextFunction · 0.85
errMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…