Skip to content

Commit

Permalink
fix Prometheus test iterator increment (#2006)
Browse files Browse the repository at this point in the history
  • Loading branch information
esigo authored Mar 1, 2023
1 parent 7c0826e commit 075f45d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions exporters/prometheus/test/exporter_utils_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,12 @@ void assert_histogram(prometheus_client::MetricFamily &metric,
int cumulative_count = 0;
auto buckets = metric.metric[0].histogram.bucket;
auto boundary_it = boundaries.cbegin();
for (size_t i = 0; i < buckets.size(); i++, ++boundary_it)
for (size_t i = 0; i < buckets.size(); i++)
{
auto bucket = buckets[i];
if (i != buckets.size() - 1)
{
ASSERT_DOUBLE_EQ(*boundary_it, bucket.upper_bound);
ASSERT_DOUBLE_EQ(*boundary_it++, bucket.upper_bound);
}
else
{
Expand Down

0 comments on commit 075f45d

Please sign in to comment.