summaryrefslogtreecommitdiffstats
path: root/tests/benchmarks/corelib/io/qfile
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2021-07-05 18:16:12 +0200
committerEdward Welbourne <edward.welbourne@qt.io>2021-07-16 17:01:24 +0200
commitcc7e0b5c2c351441f0a3f04e8471d0eac2c97601 (patch)
treeaf2e4984dde3ac1ed35a5bc7b752b90d5f275f68 /tests/benchmarks/corelib/io/qfile
parent2a71ccc232c738fda82ae3a71a42eb3f463de467 (diff)
QFile benchmark: purge fatuous function, inline several more
The empty cleanupTestCase() was just clutter. Various tests that shared a common implementation (using different data) might just as well be inline in the class body. Change-Id: I5046d7e6ad5a6425df9f9e0a0a705e229d9d0717 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/benchmarks/corelib/io/qfile')
-rw-r--r--tests/benchmarks/corelib/io/qfile/main.cpp47
1 files changed, 8 insertions, 39 deletions
diff --git a/tests/benchmarks/corelib/io/qfile/main.cpp b/tests/benchmarks/corelib/io/qfile/main.cpp
index 10a96c3f97..357205cbe8 100644
--- a/tests/benchmarks/corelib/io/qfile/main.cpp
+++ b/tests/benchmarks/corelib/io/qfile/main.cpp
@@ -80,17 +80,16 @@ public:
};
private slots:
void initTestCase();
- void cleanupTestCase();
void open_data();
void open();
void seek_data();
void seek();
- void readSmallFiles_QFile();
- void readSmallFiles_QFSFileEngine();
- void readSmallFiles_posix();
- void readSmallFiles_Win32();
+ void readSmallFiles_QFile() { readSmallFiles(); }
+ void readSmallFiles_QFSFileEngine() { readSmallFiles(); }
+ void readSmallFiles_posix() { readSmallFiles(); }
+ void readSmallFiles_Win32() { readSmallFiles(); }
void readSmallFiles_QFile_data();
void readSmallFiles_QFSFileEngine_data();
@@ -102,10 +101,10 @@ private slots:
void readBigFile_posix_data();
void readBigFile_Win32_data();
- void readBigFile_QFile();
- void readBigFile_QFSFileEngine();
- void readBigFile_posix();
- void readBigFile_Win32();
+ void readBigFile_QFile() { readBigFile(); }
+ void readBigFile_QFSFileEngine() { readBigFile(); }
+ void readBigFile_posix() { readBigFile(); }
+ void readBigFile_Win32() { readBigFile(); }
private:
void readFile_data(BenchmarkType type, QIODevice::OpenModeFlag t, QIODevice::OpenModeFlag b);
@@ -161,10 +160,6 @@ void tst_qfile::initTestCase()
{
}
-void tst_qfile::cleanupTestCase()
-{
-}
-
void tst_qfile::readFile_data(BenchmarkType type, QIODevice::OpenModeFlag t,
QIODevice::OpenModeFlag b)
{
@@ -189,17 +184,6 @@ void tst_qfile::readFile_data(BenchmarkType type, QIODevice::OpenModeFlag t,
}
}
-void tst_qfile::readBigFile_QFile() { readBigFile(); }
-void tst_qfile::readBigFile_QFSFileEngine()
-{
- readBigFile();
-}
-void tst_qfile::readBigFile_posix()
-{
- readBigFile();
-}
-void tst_qfile::readBigFile_Win32() { readBigFile(); }
-
void tst_qfile::readBigFile_QFile_data()
{
readFile_data(QFileBenchmark, QIODevice::NotOpen, QIODevice::NotOpen);
@@ -486,21 +470,6 @@ void tst_qfile::open()
removeFile();
}
-
-void tst_qfile::readSmallFiles_QFile() { readSmallFiles(); }
-void tst_qfile::readSmallFiles_QFSFileEngine()
-{
- readSmallFiles();
-}
-void tst_qfile::readSmallFiles_posix()
-{
- readSmallFiles();
-}
-void tst_qfile::readSmallFiles_Win32()
-{
- readSmallFiles();
-}
-
void tst_qfile::readSmallFiles_QFile_data()
{
readFile_data(QFileBenchmark, QIODevice::NotOpen, QIODevice::NotOpen);