summaryrefslogtreecommitdiffstats
path: root/storage/src/tests/common
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2023-02-05 19:20:55 +0000
committerHenning Baldersheim <balder@yahoo-inc.com>2023-02-05 19:20:55 +0000
commit820d83848c480086f54b53cc973c3383728a17d0 (patch)
tree95a59ebf5b4ea5ce89759f48dfb6674a88d8d329 /storage/src/tests/common
parent3659f6921137e2f930ac0ce70847bcc67d7d0d1a (diff)
Fix some fallouts after clion refactoring
Diffstat (limited to 'storage/src/tests/common')
-rw-r--r--storage/src/tests/common/metricstest.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/storage/src/tests/common/metricstest.cpp b/storage/src/tests/common/metricstest.cpp
index 5c0f951efda..290d05e9a59 100644
--- a/storage/src/tests/common/metricstest.cpp
+++ b/storage/src/tests/common/metricstest.cpp
@@ -137,8 +137,8 @@ void MetricsTest::createFakeLoad()
disk.queueSize.addValue(4 * n);
disk.averageQueueWaitingTime.addValue(10 * n);
disk.pendingMerges.addValue(4 * n);
- for (auto & j : disk.threads) {
- FileStorThreadMetrics& thread(*j);
+ for (const auto & metric : disk.threads) {
+ FileStorThreadMetrics& thread(*metric);
thread.operations.inc(120 * n);
thread.failedOperations.inc(2 * n);
@@ -180,8 +180,8 @@ void MetricsTest::createFakeLoad()
thread.merge_handler_metrics.mergeAverageDataReceivedNeeded.addValue(0.8);
}
}
- for (auto & i : _visitorMetrics->threads) {
- VisitorThreadMetrics& thread(*i);
+ for (const auto & metric : _visitorMetrics->threads) {
+ VisitorThreadMetrics& thread(*metric);
thread.queueSize.addValue(2);
thread.averageQueueWaitingTime.addValue(10);
thread.averageVisitorLifeTime.addValue(1000);
@@ -192,9 +192,7 @@ void MetricsTest::createFakeLoad()
}
_clock->addSecondsToTime(60);
_metricManager->timeChangedNotification();
- while (uint64_t(_metricManager->getLastProcessedTime())
- < _clock->getTimeInSeconds().getTime())
- {
+ while (uint64_t(_metricManager->getLastProcessedTime()) < _clock->getTimeInSeconds().getTime()) {
std::this_thread::sleep_for(5ms);
_metricManager->timeChangedNotification();
}