| 504 | } |
| 505 | |
| 506 | bool TestProblemModel::checkDisplay(int row, const QModelIndex &parent, const IProblem::Ptr &problem) |
| 507 | { |
| 508 | QModelIndex idx; |
| 509 | |
| 510 | idx = m_model->index(row, 0, parent); |
| 511 | MYVERIFY(idx.isValid()); |
| 512 | MYCOMPARE(m_model->data(idx).toString(), problem->description()); |
| 513 | |
| 514 | idx = m_model->index(row, 1, parent); |
| 515 | MYVERIFY(idx.isValid()); |
| 516 | MYCOMPARE(m_model->data(idx).toString(), problem->sourceString()); |
| 517 | |
| 518 | idx = m_model->index(row, 2, parent); |
| 519 | MYVERIFY(idx.isValid()); |
| 520 | MYCOMPARE(m_model->data(idx).toString(), problem->finalLocation().document.str()); |
| 521 | |
| 522 | idx = m_model->index(row, 3, parent); |
| 523 | MYVERIFY(idx.isValid()); |
| 524 | MYCOMPARE(m_model->data(idx).toString(), QString::number(problem->finalLocation().start().line() + 1)); |
| 525 | |
| 526 | idx = m_model->index(row, 4, parent); |
| 527 | MYVERIFY(idx.isValid()); |
| 528 | MYCOMPARE(m_model->data(idx).toString(), QString::number(problem->finalLocation().start().column() + 1)); |
| 529 | |
| 530 | return true; |
| 531 | } |
| 532 | |
| 533 | bool TestProblemModel::checkLabel(int row, const QModelIndex &parent, const QString &label) |
| 534 | { |
nothing calls this directly
no test coverage detected