| 297 | |
| 298 | template <typename T> |
| 299 | ProblemPointer findProblemWithAssistant(const QVector<ProblemPointer>& problems) |
| 300 | { |
| 301 | const auto problemIterator = std::find_if(problems.cbegin(), problems.cend(), [](const ProblemPointer& p) { |
| 302 | return dynamic_cast<const T*>(p->solutionAssistant().constData()); |
| 303 | }); |
| 304 | if (problemIterator != problems.cend()) |
| 305 | return *problemIterator; |
| 306 | |
| 307 | return {}; |
| 308 | } |
| 309 | |
| 310 | void TestAssistants::testRenameAssistant() |
| 311 | { |
nothing calls this directly
no test coverage detected