diff options
| author | chenzizhan <[email protected]> | 2024-07-26 18:02:29 +0800 |
|---|---|---|
| committer | chenzizhan <[email protected]> | 2024-07-26 18:02:29 +0800 |
| commit | 240bbbb0e0409a6bca409eb319a0a00960cbc6fb (patch) | |
| tree | b15ddd24d6b851ccf797a5919df52d7994e4dbc9 /test/test_fieldstat_exporter.py | |
| parent | 3f46275f81d2d5af416f27fb24ab2c5ac21ec418 (diff) | |
| parent | 97e8724310c1a0d51600d723c6d3dcb6c4495d5f (diff) | |
Merge branch 'refactor-heavykeeper-newkey' into develop-version4
Diffstat (limited to 'test/test_fieldstat_exporter.py')
| -rw-r--r-- | test/test_fieldstat_exporter.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/test_fieldstat_exporter.py b/test/test_fieldstat_exporter.py index aaafb16..4f82f1a 100644 --- a/test/test_fieldstat_exporter.py +++ b/test/test_fieldstat_exporter.py @@ -17,6 +17,7 @@ from prettytable import PrettyTable,NONE,HEADER import os current_path = os.path.dirname(os.path.abspath(__file__)) sys.path.append(current_path + '/../../src/exporter') +sys.path.append('/home/chenzizhan/heavykeeperczz/FieldStat/src/exporter') from fieldstat_exporter import FieldstatAPI @@ -153,7 +154,7 @@ class TestPrometheusExporter(unittest.TestCase): metric = self.prom._PrometheusExporter__build_type_hll(name, tags, value) - self.assertEqual(metric, "tsg_master_log{policy_id=\"1\",app_name=\"-\"} 62.61\n") + self.assertEqual(metric, "tsg_master_log{policy_id=\"1\",app_name=\"-\"} 93.61\n") def test__build_metrics(self): @@ -186,7 +187,7 @@ class TestPrometheusExporter(unittest.TestCase): "timestamp_ms_delta": 100010 } metrics = self.prom._PrometheusExporter__build_metrics(hll_dict) - self.assertEqual(metrics, "external_ip{rule_id=\"1\",app_name=\"-\"} 62.61\n") + self.assertEqual(metrics, "external_ip{rule_id=\"1\",app_name=\"-\"} 93.61\n") hist_dict = {"name": "-", "tags": { |
