summaryrefslogtreecommitdiff
path: root/tests/test_main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_main.cpp')
-rw-r--r--tests/test_main.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/test_main.cpp b/tests/test_main.cpp
index 4cdc5ea1fa..a5f6fb9b88 100644
--- a/tests/test_main.cpp
+++ b/tests/test_main.cpp
@@ -105,9 +105,9 @@ int test_main(int argc, char *argv[]) {
// Run custom test tools.
if (test_commands) {
- for (Map<String, TestFunc>::Element *E = test_commands->front(); E; E = E->next()) {
- if (args.find(E->key())) {
- const TestFunc &test_func = E->get();
+ for (const KeyValue<String, TestFunc> &E : (*test_commands)) {
+ if (args.find(E.key)) {
+ const TestFunc &test_func = E.value;
test_func();
run_tests = false;
break;