X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/848abc5922167a467bb73107ee6b72e9af3c8317..e133c4557ecc37ed3f7e1b9:/src/tests/placesitemmodeltest.cpp diff --git a/src/tests/placesitemmodeltest.cpp b/src/tests/placesitemmodeltest.cpp index ec44c8f31..fc21ce055 100644 --- a/src/tests/placesitemmodeltest.cpp +++ b/src/tests/placesitemmodeltest.cpp @@ -228,7 +228,8 @@ void PlacesItemModelTest::init() void PlacesItemModelTest::cleanup() { - for (int i : m_tobeRemoved) { + const auto tobeRemoved = m_tobeRemoved; + for (const int i : tobeRemoved) { int before = m_model->count(); m_model->deleteItem(i); QTRY_COMPARE(m_model->count(), before - 1); @@ -541,7 +542,6 @@ void PlacesItemModelTest::testSystemItems() void PlacesItemModelTest::testEditBookmark() { - const QUrl tempUrl = QUrl::fromLocalFile(QStandardPaths::writableLocation(QStandardPaths::TempLocation)); QScopedPointer other(new PlacesItemModel()); createPlaceItem(QStringLiteral("Temporary Dir"), QUrl::fromLocalFile(QStandardPaths::writableLocation(QStandardPaths::TempLocation)), QString());