tst_qsidebar: remove duplicate code
Change-Id: I8ee59022199fda7ea56891a2f924954cb4aefa42 Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
This commit is contained in:
parent
aae8b745d2
commit
12130ff65f
@ -190,19 +190,16 @@ void tst_QSidebar::addUrls()
|
||||
qsidebar.addUrls(doubleUrls, 1);
|
||||
QCOMPARE(qsidebar.urls().size(), 1);
|
||||
|
||||
#if defined(Q_OS_WIN)
|
||||
//Windows is case insensitive so no duplicate entries in that case
|
||||
doubleUrls << QUrl::fromLocalFile(testDir.absolutePath());
|
||||
doubleUrls << QUrl::fromLocalFile(testDir.absolutePath().toUpper());
|
||||
qsidebar.setUrls(emptyUrls);
|
||||
qsidebar.addUrls(doubleUrls, 1);
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
//Windows is case insensitive so no duplicate entries in that case
|
||||
QCOMPARE(qsidebar.urls().size(), 1);
|
||||
#else
|
||||
//Two different paths we should have two entries
|
||||
doubleUrls << QUrl::fromLocalFile(testDir.absolutePath());
|
||||
doubleUrls << QUrl::fromLocalFile(testDir.absolutePath().toUpper());
|
||||
qsidebar.setUrls(emptyUrls);
|
||||
qsidebar.addUrls(doubleUrls, 1);
|
||||
QCOMPARE(qsidebar.urls().size(), 2);
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user