| 155 | } |
| 156 | |
| 157 | void TestView::notifyTestCaseStarted(ITestSuite* suite, const QStringList& test_cases) |
| 158 | { |
| 159 | QStandardItem* item = itemForSuite(suite); |
| 160 | if (!item) |
| 161 | { |
| 162 | return; |
| 163 | } |
| 164 | |
| 165 | qCDebug(PLUGIN_TESTVIEW) << "Notify a test of the suite " << suite->name() << " has started"; |
| 166 | |
| 167 | // Global test suite icon |
| 168 | item->setIcon(QIcon::fromTheme(QStringLiteral("process-idle"))); |
| 169 | |
| 170 | for (int i = 0; i < item->rowCount(); ++i) |
| 171 | { |
| 172 | qCDebug(PLUGIN_TESTVIEW) << "Found a test case" << item->child(i)->text(); |
| 173 | QStandardItem* caseItem = item->child(i); |
| 174 | if (test_cases.contains(caseItem->text())) |
| 175 | { |
| 176 | // Each test case icon |
| 177 | caseItem->setIcon(QIcon::fromTheme(QStringLiteral("process-idle"))); |
| 178 | } |
| 179 | } |
| 180 | } |
| 181 | |
| 182 | |
| 183 | QIcon TestView::iconForTestResult(TestResult::TestCaseResult result) |