diff options
author | Olivier Goffart <ogoffart@trolltech.com> | 2009-07-20 16:55:44 (GMT) |
---|---|---|
committer | Olivier Goffart <ogoffart@trolltech.com> | 2009-07-20 16:56:43 (GMT) |
commit | 4c0c652b846e248d076739a6e2f00a3a3d9a414f (patch) | |
tree | 00d16cacc5e08eb10d65555f57f8a4ff9691f20c | |
parent | a522652fc919f3bff8772bb2b7bd291d10eb4f12 (diff) | |
download | Qt-4c0c652b846e248d076739a6e2f00a3a3d9a414f.zip Qt-4c0c652b846e248d076739a6e2f00a3a3d9a414f.tar.gz Qt-4c0c652b846e248d076739a6e2f00a3a3d9a414f.tar.bz2 |
Use QVERIFY in benchmarks, insteads of returning silently in case of error
-rw-r--r-- | tests/benchmarks/qdir/tst_qdir.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/benchmarks/qdir/tst_qdir.cpp b/tests/benchmarks/qdir/tst_qdir.cpp index edb2811..7977e28 100644 --- a/tests/benchmarks/qdir/tst_qdir.cpp +++ b/tests/benchmarks/qdir/tst_qdir.cpp @@ -87,8 +87,7 @@ private slots: WIN32_FIND_DATA fd; HANDLE hSearch = FindFirstFileW(appendedPath, &fd); - if (hSearch != INVALID_HANDLE_VALUE) - return; + QVERIFY(hSearch == INVALID_HANDLE_VALUE); QBENCHMARK { do { @@ -99,8 +98,7 @@ private slots: #else QDir testdir(QDir::tempPath() + QLatin1String("/test_speed")); DIR *dir = opendir(qPrintable(testdir.absolutePath())); - if (!dir) - return; + QVERIFY(dir); QVERIFY(!chdir(qPrintable(testdir.absolutePath()))); QBENCHMARK { |