summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp')
-rw-r--r--tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp b/tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp
index e814e79dbe..4fe998f43e 100644
--- a/tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp
+++ b/tests/auto/gui/itemmodels/qfilesystemmodel/tst_qfilesystemmodel.cpp
@@ -226,6 +226,21 @@ void tst_QFileSystemModel::rootPath()
QCOMPARE(rootChanged.count(), oldCount + 1);
QCOMPARE(model->rootDirectory().absolutePath(), newdir.path());
}
+
+#ifdef Q_OS_WIN
+ // check case insensitive root node on windows, tests QTBUG-71701
+ QModelIndex index = model->setRootPath(QString("\\\\localhost\\c$"));
+ QVERIFY(index.isValid());
+ QCOMPARE(model->rootPath(), QString("//localhost/c$"));
+
+ index = model->setRootPath(QString("\\\\localhost\\C$"));
+ QVERIFY(index.isValid());
+ QCOMPARE(model->rootPath(), QString("//localhost/C$"));
+
+ index = model->setRootPath(QString("\\\\LOCALHOST\\C$"));
+ QVERIFY(index.isValid());
+ QCOMPARE(model->rootPath(), QString("//LOCALHOST/C$"));
+#endif
}
void tst_QFileSystemModel::readOnly()