summaryrefslogtreecommitdiffstats
path: root/tests/auto/qdir
diff options
context:
space:
mode:
authorShane Kearns <shane.kearns@accenture.com>2011-02-23 15:28:54 (GMT)
committerShane Kearns <shane.kearns@accenture.com>2011-02-24 16:43:07 (GMT)
commit8d1ee3335f4c1bf262fb3a85fd4cc7e837129b8c (patch)
tree58c68ef568605b3b8904f156b9269d54ee714373 /tests/auto/qdir
parentdc01a7829255a41bda606fb59f546d599b6654ba (diff)
downloadQt-8d1ee3335f4c1bf262fb3a85fd4cc7e837129b8c.zip
Qt-8d1ee3335f4c1bf262fb3a85fd4cc7e837129b8c.tar.gz
Qt-8d1ee3335f4c1bf262fb3a85fd4cc7e837129b8c.tar.bz2
bugfix: QDir::entryList(Files|Readable) not listing writable files
Mistake in the qfilesystemiterator_symbian implementation. Readable without Writable was thought to mean show only read-only files, but this isn't the expected behaviour of QDir[Iterator] Added an autotest, as this was only covered by ssl tests in the network layer. Reviewed-by: joao
Diffstat (limited to 'tests/auto/qdir')
-rw-r--r--tests/auto/qdir/tst_qdir.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/auto/qdir/tst_qdir.cpp b/tests/auto/qdir/tst_qdir.cpp
index 2fa0c24..21460be 100644
--- a/tests/auto/qdir/tst_qdir.cpp
+++ b/tests/auto/qdir/tst_qdir.cpp
@@ -571,6 +571,12 @@ void tst_QDir::entryList_data()
<< int(QDir::AllEntries | QDir::Writable) << int(QDir::Name)
<< filterLinks(QString(".,..,directory,linktodirectory.lnk,writable").split(','));
#endif
+ QTest::newRow("QDir::Files | QDir::Readable") << SRCDIR "entrylist/" << QStringList("*")
+ << int(QDir::Files | QDir::Readable) << int(QDir::Name)
+ << filterLinks(QString("file,linktofile.lnk,writable").split(','));
+ QTest::newRow("QDir::Dirs | QDir::Readable") << SRCDIR "entrylist/" << QStringList("*")
+ << int(QDir::Dirs | QDir::Readable) << int(QDir::Name)
+ << filterLinks(QString(".,..,directory,linktodirectory.lnk").split(','));
QTest::newRow("Namefilters b*") << SRCDIR "entrylist/" << QStringList("d*")
<< int(QDir::NoFilter) << int(QDir::Name)
<< filterLinks(QString("directory").split(','));