test: fixed tst_qfilesystemmodel and removed insignificant_test

tst_qfilesystemmodel::sort uses some internal API to affect the sorting
behavior.  This means that part of the test must be disabled when
private symbols aren't available.

Change-Id: I2e7b9d7a33cb3e7032bc5380c03fa29ecc84e12c
Reviewed-on: http://codereview.qt.nokia.com/2413
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
This commit is contained in:
Rohan McGovern 2011-08-01 14:21:56 +10:00 committed by Qt by Nokia
parent 30eff894d9
commit 4e84be2876
2 changed files with 4 additions and 2 deletions

View File

@ -14,5 +14,3 @@ symbian: {
DEPLOYMENT += dummyDeploy
LIBS += -lefsrv
}
CONFIG+=insignificant_test

View File

@ -909,12 +909,16 @@ void tst_QFileSystemModel::sort()
expectedOrder << tempFile2.fileName() << tempFile.fileName() << dirPath + QChar('/') + "." << dirPath + QChar('/') + "..";
//File dialog Mode means sub trees are not sorted, only the current root
if (fileDialogMode) {
// FIXME: we were only able to disableRecursiveSort in developer builds, so we can only
// stably perform this test for developer builds
#ifdef QT_BUILD_INTERNAL
QList<QString> actualRows;
for(int i = 0; i < myModel->rowCount(parent); ++i)
{
actualRows << dirPath + QChar('/') + myModel->index(i, 1, parent).data(QFileSystemModel::FileNameRole).toString();
}
QVERIFY(actualRows != expectedOrder);
#endif
} else {
for(int i = 0; i < myModel->rowCount(parent); ++i)
{