| 65 | } |
| 66 | |
| 67 | OutputWidget* StandardOutputViewTest::toolViewPointer(const QString& toolViewTitle) |
| 68 | { |
| 69 | const QList< Sublime::View* > views = m_controller->activeArea()->toolViews(); |
| 70 | for (const auto* const view : views) { |
| 71 | auto* doc = qobject_cast<Sublime::ToolDocument*>(view->document()); |
| 72 | if (doc && doc->title() == toolViewTitle) { |
| 73 | if (auto* const widget = view->widget()) { |
| 74 | // cannot use qobject_cast here, test code currently slightly fragile due to |
| 75 | // duplicated compilation of OutputWidget, here & loaded plugin |
| 76 | // cmp. comment in CMakeLists.txt |
| 77 | return dynamic_cast<OutputWidget*>(widget); |
| 78 | } |
| 79 | } |
| 80 | } |
| 81 | return nullptr; |
| 82 | } |
| 83 | |
| 84 | void StandardOutputViewTest::testRegisterAndRemoveToolView() |
| 85 | { |
nothing calls this directly
no test coverage detected