MCPcopy Index your code
hub / github.com/prometheus/client_python / test_summary

Method test_summary

tests/test_core.py:801–804  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

799 self.assertEqual(2, self.registry.get_sample_value('g', {'a': 'b'}))
800
801 def test_summary(self):
802 self.custom_collector(SummaryMetricFamily('s', 'help', count_value=1, sum_value=2))
803 self.assertEqual(1, self.registry.get_sample_value('s_count', {}))
804 self.assertEqual(2, self.registry.get_sample_value('s_sum', {}))
805
806 def test_summary_labels(self):
807 cmf = SummaryMetricFamily('s', 'help', labels=['a'])

Callers

nothing calls this directly

Calls 3

custom_collectorMethod · 0.95
SummaryMetricFamilyClass · 0.90
get_sample_valueMethod · 0.80

Tested by

no test coverage detected