summaryrefslogtreecommitdiffstats
path: root/tests/auto/qzip/tst_qzip.cpp
diff options
context:
space:
mode:
authorRitt Konstantin <ritt.ks@gmail.com>2010-03-10 11:30:08 (GMT)
committerBenjamin Poulain <benjamin.poulain@nokia.com>2010-03-10 11:30:08 (GMT)
commit17ab2405fab50497c1f79c8e513fcfdf31979974 (patch)
treed9d71817f6daba39a4074aa10eea460cf6bf4c4f /tests/auto/qzip/tst_qzip.cpp
parent5746fb12c6e7353483cf130b83fb2ab88f0217a2 (diff)
downloadQt-17ab2405fab50497c1f79c8e513fcfdf31979974.zip
Qt-17ab2405fab50497c1f79c8e513fcfdf31979974.tar.gz
Qt-17ab2405fab50497c1f79c8e513fcfdf31979974.tar.bz2
Add isValid() method to QZipReader::FileInfo.
Reviewed-by: Benjamin Poulain <benjamin.poulain@nokia.com>
Diffstat (limited to 'tests/auto/qzip/tst_qzip.cpp')
-rw-r--r--tests/auto/qzip/tst_qzip.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/auto/qzip/tst_qzip.cpp b/tests/auto/qzip/tst_qzip.cpp
index d7fc2f7..99379b5 100644
--- a/tests/auto/qzip/tst_qzip.cpp
+++ b/tests/auto/qzip/tst_qzip.cpp
@@ -77,6 +77,7 @@ void tst_QZip::basicUnpack()
QCOMPARE(files.count(), 2);
QZipReader::FileInfo fi = files.at(0);
+ QVERIFY(fi.isValid());
QCOMPARE(fi.filePath, QString("test/"));
QCOMPARE(uint(fi.isDir), (uint) 1);
QCOMPARE(uint(fi.isFile), (uint) 0);
@@ -86,6 +87,7 @@ void tst_QZip::basicUnpack()
| QFile::ReadUser | QFile::WriteUser | QFile::ExeUser ));
fi = files.at(1);
+ QVERIFY(fi.isValid());
QCOMPARE(fi.filePath, QString("test/test.txt"));
QCOMPARE(uint(fi.isDir), (uint) 0);
QCOMPARE(uint(fi.isFile), (uint) 1);
@@ -104,6 +106,7 @@ void tst_QZip::symlinks()
QCOMPARE(files.count(), 2);
QZipReader::FileInfo fi = files.at(0);
+ QVERIFY(fi.isValid());
QCOMPARE(fi.filePath, QString("symlink"));
QVERIFY(!fi.isDir);
QVERIFY(!fi.isFile);
@@ -112,6 +115,7 @@ void tst_QZip::symlinks()
QCOMPARE(zip.fileData("symlink"), QByteArray("destination"));
fi = files.at(1);
+ QVERIFY(fi.isValid());
QCOMPARE(fi.filePath, QString("destination"));
QVERIFY(!fi.isDir);
QVERIFY(fi.isFile);