summaryrefslogtreecommitdiffstats
path: root/src/testlib/qbenchmark.cpp
diff options
context:
space:
mode:
authorSamuel Rødal <samuel.rodal@nokia.com>2011-09-06 10:49:40 +0200
committerSamuel Rødal <samuel.rodal@nokia.com>2011-09-06 10:55:40 +0200
commita6b6e760ac2f019b9ca42847b9535207966811aa (patch)
treecdba2823eb3708f7a40593ff69b81d2be88515ea /src/testlib/qbenchmark.cpp
parent48ba459580c9e4ce28dbb2c3ce433175148da5a1 (diff)
parent8ed47d961dc7e6f161030654d11cd330a542eadf (diff)
Merge remote branch 'gerrit/master' into HEAD
Conflicts: configure.exe src/corelib/global/qglobal.h src/gui/kernel/qplatformnativeinterface_qpa.h src/gui/widgets/qlinecontrol.cpp src/gui/widgets/qmenu_mac.mm src/gui/widgets/qmenu_p.h src/gui/widgets/qmenubar.cpp src/gui/widgets/qmenubar_p.h src/gui/widgets/widgets.pri src/plugins/platforms/wayland/qwaylandnativeinterface.cpp src/plugins/platforms/wayland/qwaylandnativeinterface.h src/src.pro tests/auto/qdir/tst_qdir.cpp tests/auto/qfileinfo/tst_qfileinfo.cpp tests/auto/qsslsocket/tst_qsslsocket.cpp tests/auto/qstring/tst_qstring.cpp Change-Id: I64cf2cefa532ba87a92f632e3595ce6914183e9b
Diffstat (limited to 'src/testlib/qbenchmark.cpp')
-rw-r--r--src/testlib/qbenchmark.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/testlib/qbenchmark.cpp b/src/testlib/qbenchmark.cpp
index 1cb10a7ac6..49fad5da4d 100644
--- a/src/testlib/qbenchmark.cpp
+++ b/src/testlib/qbenchmark.cpp
@@ -119,7 +119,6 @@ QBenchmarkTestMethodData *QBenchmarkTestMethodData::current;
QBenchmarkTestMethodData::QBenchmarkTestMethodData()
:resultAccepted(false), runOnce(false), iterationCount(-1)
{
-
}
QBenchmarkTestMethodData::~QBenchmarkTestMethodData()
@@ -134,7 +133,6 @@ void QBenchmarkTestMethodData::beginDataRun()
void QBenchmarkTestMethodData::endDataRun()
{
-
}
int QBenchmarkTestMethodData::adjustIterationCount(int suggestion)
@@ -164,7 +162,7 @@ void QBenchmarkTestMethodData::setResult(
accepted = true;
}
- // Test the result directly without calling the measurer if the minimum time
+ // Test the result directly without calling the measurer if the minimum time
// has been specified on the command line with -minimumvalue.
else if (QBenchmarkGlobalData::current->walltimeMinimum != -1)
accepted = (value > QBenchmarkGlobalData::current->walltimeMinimum);
@@ -196,7 +194,7 @@ QTest::QBenchmarkIterationController::QBenchmarkIterationController(RunMode runM
{
i = 0;
if (runMode == RunOnce)
- QBenchmarkTestMethodData::current->runOnce = true;
+ QBenchmarkTestMethodData::current->runOnce = true;
QTest::beginBenchmarkMeasurement();
}
@@ -265,16 +263,16 @@ void QTest::beginBenchmarkMeasurement()
quint64 QTest::endBenchmarkMeasurement()
{
// the clock is ticking before the line below, don't add code here.
- return QBenchmarkGlobalData::current->measurer->stop();
+ return QBenchmarkGlobalData::current->measurer->stop();
}
/*!
Sets the benchmark result for this test function to \a result.
-
+
Use this function if you want to report benchmark results without
using the QBENCHMARK macro. Use \a metric to specify how QTestLib
should interpret the results.
-
+
The context for the result will be the test function name and any
data tag from the _data function. This function can only be called
once in each test function, subsequent calls will replace the