Commit 45f1a625 authored by Emmanuel Promayon's avatar Emmanuel Promayon
Browse files

FIXED code cleaning

parent dd3740f5
......@@ -163,7 +163,7 @@ int main(int argc, char* argv[]) {
std::cout << "Found " << allActions.size() << " actions." << std::endl;
testSuccess();
std::map<Action::ApplyStatus, int> statusCount;
int skippedCount = 0;
......@@ -171,16 +171,17 @@ int main(int argc, char* argv[]) {
std::cout << std::endl;
Action* action = allActions.at(i);
if (!action->getEmbedded()) {
std::cout << (i+1) << ". Skipping action " << action->getName().toStdString() << " as it is not embedded and might require user interaction." << std::endl;
std::cout << (i + 1) << ". Skipping autotest for action " << action->getName().toStdString() << " as it is not embedded and might require user interaction." << std::endl;
// post the events before calling the action
skippedCount++;
}
else {
std::cout << (i+1) << ". Applying action " + action->getName().toStdString() << "..." << std::endl;
std::cout << (i + 1) << ". Applying action " + action->getName().toStdString() << "..." << std::endl;
action->setInputComponent(comp);
Action::ApplyStatus status = action->apply();
statusCount[status]++;
std::string statusString;
switch (status) {
case Action::ERROR:
......@@ -200,8 +201,8 @@ int main(int argc, char* argv[]) {
break;
}
std::cout << "Return status is: " << statusString << std::endl;
}
std::cout << "Return status is: " << statusString << std::endl;
}
}
std::cout << std::endl;
......@@ -215,7 +216,7 @@ int main(int argc, char* argv[]) {
std::cout << percentage << "% tests passed, " << failedCount << " tests failed out of " << totalCount << " runs, ";
std::cout << skippedCount << " skipped." << std::endl;
std::cout << statusCount[Action::SUCCESS] << " SUCCESS, " << statusCount[Action::ABORTED] << " ABORTED (please check if this is the expected behaviour)." << std::endl;
if (failedCount == 0) {
testSuccess();
return EXIT_SUCCESS;
......
Supports Markdown
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