diff --git a/tests/tests_launcher.cpp b/tests/tests_launcher.cpp index 5a2e4974..a4fe2032 100644 --- a/tests/tests_launcher.cpp +++ b/tests/tests_launcher.cpp @@ -106,20 +106,20 @@ int main(int argv, char**argc) } bool ok = false; - const int subsetNumber = app.arguments()[1].toInt(&ok); + const int subsetNumber = app.arguments().at(1).toInt(&ok); if (!ok) { - qWarning() << "Invalid number" << app.arguments()[1]; + qWarning() << "Invalid number" << app.arguments().at(1); return -1; } - const int subsetPercentage = app.arguments()[2].toInt(&ok); + const int subsetPercentage = app.arguments().at(2).toInt(&ok); if (!ok) { - qWarning() << "Invalid number" << app.arguments()[2]; + qWarning() << "Invalid number" << app.arguments().at(2); return -1; } if (subsetPercentage > 100 || subsetPercentage <= 0) { - qWarning() << "Invalid percentage" << app.arguments()[2]; + qWarning() << "Invalid percentage" << app.arguments().at(2); return -1; } diff --git a/tests/tst_multisplitter.cpp b/tests/tst_multisplitter.cpp index f7a0af27..d74d5d2f 100644 --- a/tests/tst_multisplitter.cpp +++ b/tests/tst_multisplitter.cpp @@ -1586,7 +1586,7 @@ void TestMultiSplitter::tst_separatorMoveCrash() root->insertItem(item6, Item::Location_OnRight); ItemContainer *c = item5->parentContainer(); - auto separator = c->separators()[0]; + auto separator = c->separators().constFirst(); const int available5 = item5->availableLength(Qt::Horizontal);