summaryrefslogtreecommitdiffstats
path: root/tests/benchmarks
diff options
context:
space:
mode:
Diffstat (limited to 'tests/benchmarks')
-rw-r--r--tests/benchmarks/network/ssl/qsslsocket/tst_qsslsocket.cpp13
-rw-r--r--tests/benchmarks/script/sunspider/tst_sunspider.cpp2
-rw-r--r--tests/benchmarks/script/v8/tst_v8.cpp4
3 files changed, 15 insertions, 4 deletions
diff --git a/tests/benchmarks/network/ssl/qsslsocket/tst_qsslsocket.cpp b/tests/benchmarks/network/ssl/qsslsocket/tst_qsslsocket.cpp
index 6cb62d0..041b61a 100644
--- a/tests/benchmarks/network/ssl/qsslsocket/tst_qsslsocket.cpp
+++ b/tests/benchmarks/network/ssl/qsslsocket/tst_qsslsocket.cpp
@@ -46,7 +46,7 @@
#include <qsslsocket.h>
-// #include "../../../../auto/network-settings.h"
+#include "../../../../auto/network-settings.h"
//TESTED_CLASS=
//TESTED_FILES=
@@ -65,6 +65,7 @@ public slots:
void init();
void cleanup();
private slots:
+ void rootCertLoading();
void systemCaCertificates();
};
@@ -89,6 +90,16 @@ void tst_QSslSocket::cleanup()
}
//----------------------------------------------------------------------------------
+
+void tst_QSslSocket::rootCertLoading()
+{
+ QBENCHMARK_ONCE {
+ QSslSocket socket;
+ socket.connectToHostEncrypted(QtNetworkSettings::serverName(), 443);
+ socket.waitForEncrypted();
+ }
+}
+
void tst_QSslSocket::systemCaCertificates()
{
// The results of this test change if the benchmarking system changes too much.
diff --git a/tests/benchmarks/script/sunspider/tst_sunspider.cpp b/tests/benchmarks/script/sunspider/tst_sunspider.cpp
index 0df19b6..9e2bb6f 100644
--- a/tests/benchmarks/script/sunspider/tst_sunspider.cpp
+++ b/tests/benchmarks/script/sunspider/tst_sunspider.cpp
@@ -110,7 +110,7 @@ void tst_SunSpider::benchmark_data()
void tst_SunSpider::benchmark()
{
QFETCH(QString, testName);
- QString testContents = readFile(testsDir.absoluteFilePath(testName + ".js"));
+ QString testContents = readFile(testsDir.filePath(testName + ".js"));
QVERIFY(!testContents.isEmpty());
QScriptEngine engine;
diff --git a/tests/benchmarks/script/v8/tst_v8.cpp b/tests/benchmarks/script/v8/tst_v8.cpp
index 841e2f3..b9cb859 100644
--- a/tests/benchmarks/script/v8/tst_v8.cpp
+++ b/tests/benchmarks/script/v8/tst_v8.cpp
@@ -115,10 +115,10 @@ void tst_V8::benchmark()
{
QFETCH(QString, testName);
- QString baseDotJsContents = readFile(testsDir.absoluteFilePath("base.js"));
+ QString baseDotJsContents = readFile(testsDir.filePath("base.js"));
QVERIFY(!baseDotJsContents.isEmpty());
- QString testContents = readFile(testsDir.absoluteFilePath(testName + ".js"));
+ QString testContents = readFile(testsDir.filePath(testName + ".js"));
QVERIFY(!testContents.isEmpty());
QScriptEngine engine;