Unverified Commit 80d5177d authored by ppenguin's avatar ppenguin Committed by GitHub
Browse files

Use count function instead of handwritten loop

parent 011959aa
......@@ -78,17 +78,7 @@ const char* TypedTestSuitePState::VerifyRegisteredTestNames(
continue;
}
bool found = false;
for (RegisteredTestIter it = registered_tests_.begin();
it != registered_tests_.end();
++it) {
if (name == it->first) {
found = true;
break;
}
}
if (found) {
if (registered_tests_.count(name) != 0) {
tests.insert(name);
} else {
errors << "No test named " << name
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment