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

Unified Diff: infra_libs/ts_mon/common/metrics.py

Issue 2109393002: Make test_net_info a bit more robust. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Add tests Created 4 years, 6 months 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
« no previous file with comments | « infra_libs/ts_mon/common/metric_store.py ('k') | infra_libs/ts_mon/common/test/metric_store_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: infra_libs/ts_mon/common/metrics.py
diff --git a/infra_libs/ts_mon/common/metrics.py b/infra_libs/ts_mon/common/metrics.py
index 28969e5f64c60a7a47a3fb69ae7f368621a29e39..4596f4c90885aa259ca405e8b60c7448017330ee 100644
--- a/infra_libs/ts_mon/common/metrics.py
+++ b/infra_libs/ts_mon/common/metrics.py
@@ -185,6 +185,9 @@ class Metric(object):
return interface.state.store.get(
self.name, self._normalize_fields(fields), target_fields)
+ def get_all(self):
+ return interface.state.store.iter_field_values(self.name)
+
def reset(self):
"""Clears the values of this metric. Useful in unit tests.
« no previous file with comments | « infra_libs/ts_mon/common/metric_store.py ('k') | infra_libs/ts_mon/common/test/metric_store_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698