┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorElvis Angelaccio <[email protected]>2019-05-05 17:05:46 +0200
committerElvis Angelaccio <[email protected]>2019-05-05 17:53:29 +0200
commit957a6f4f31d6a50682cb3ac16447dc72498afea9 (patch)
tree901dc591e8f4b465c34f04eaf401a5303dd9f5e3 /src
parentafbef7d894250766b4d982c2805e71155db4ad9f (diff)
[PlacesItemModelTest] Rename variable
This variable is not the expected size of the groups list, but it's the expected index of the 'Remote' group in the model.
Diffstat (limited to 'src')
-rw-r--r--src/tests/placesitemmodeltest.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/tests/placesitemmodeltest.cpp b/src/tests/placesitemmodeltest.cpp
index 7f0d498a7..78c5eabfe 100644
--- a/src/tests/placesitemmodeltest.cpp
+++ b/src/tests/placesitemmodeltest.cpp
@@ -292,12 +292,12 @@ void PlacesItemModelTest::testModelSort()
void PlacesItemModelTest::testGroups()
{
const auto groups = m_model->groups();
- int expectedGroupSize = 3;
+ int expectedRemoteIndex = 3;
if (m_hasDesktopFolder) {
- expectedGroupSize++;
+ expectedRemoteIndex++;
}
if (m_hasDownloadsFolder) {
- expectedGroupSize++;
+ expectedRemoteIndex++;
}
QCOMPARE(groups.size(), 6);
@@ -305,19 +305,19 @@ void PlacesItemModelTest::testGroups()
QCOMPARE(groups.at(0).first, 0);
QCOMPARE(groups.at(0).second.toString(), QStringLiteral("Places"));
- QCOMPARE(groups.at(1).first, expectedGroupSize);
+ QCOMPARE(groups.at(1).first, expectedRemoteIndex);
QCOMPARE(groups.at(1).second.toString(), QStringLiteral("Remote"));
- QCOMPARE(groups.at(2).first, expectedGroupSize + 2);
+ QCOMPARE(groups.at(2).first, expectedRemoteIndex + 2);
QCOMPARE(groups.at(2).second.toString(), QStringLiteral("Recently Saved"));
- QCOMPARE(groups.at(3).first, expectedGroupSize + 4);
+ QCOMPARE(groups.at(3).first, expectedRemoteIndex + 4);
QCOMPARE(groups.at(3).second.toString(), QStringLiteral("Search For"));
- QCOMPARE(groups.at(4).first, expectedGroupSize + 8);
+ QCOMPARE(groups.at(4).first, expectedRemoteIndex + 8);
QCOMPARE(groups.at(4).second.toString(), QStringLiteral("Devices"));
- QCOMPARE(groups.at(5).first, expectedGroupSize + 9);
+ QCOMPARE(groups.at(5).first, expectedRemoteIndex + 9);
QCOMPARE(groups.at(5).second.toString(), QStringLiteral("Removable Devices"));
}