Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(691)

Unified Diff: base/test/histogram_tester.cc

Issue 2393493002: Expose macros from base/metrics/histogram_macros.h as functions (Closed)
Patch Set: Review comments Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« base/metrics/histogram_macros.h ('K') | « base/test/histogram_tester.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/test/histogram_tester.cc
diff --git a/base/test/histogram_tester.cc b/base/test/histogram_tester.cc
index 65c4285c210646ccfcdf8eaea5ba4eea8071c09a..90981e232637f8eb3323c96f9f22dc9538c5b89a 100644
--- a/base/test/histogram_tester.cc
+++ b/base/test/histogram_tester.cc
@@ -78,6 +78,13 @@ void HistogramTester::ExpectTotalCount(const std::string& name,
}
}
+void HistogramTester::ExpectTimeBucketCount(
+ const std::string& name,
+ base::TimeDelta sample,
+ base::HistogramBase::Count count) const {
+ ExpectBucketCount(name, sample.InMilliseconds(), count);
+}
+
std::vector<Bucket> HistogramTester::GetAllSamples(
const std::string& name) const {
std::vector<Bucket> samples;
« base/metrics/histogram_macros.h ('K') | « base/test/histogram_tester.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698