summaryrefslogtreecommitdiffstats
path: root/tests/benchmarks/corelib
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2021-07-07 17:02:05 +0200
committerEdward Welbourne <edward.welbourne@qt.io>2021-07-15 15:06:54 +0000
commitbf99c2b62bc3bc2dc10ba8f98bea0496b2026801 (patch)
treecad7f59c3b6a7c514e99edee92b3102d4f1406b4 /tests/benchmarks/corelib
parent90d9a86c2e762c9426d0facbd54ed5dbff574ecd (diff)
Fix qdbusperformance and qprocess benchmarks
The tests failed because they couldn't find the servers they needed to run. The dbus server wasn't being built, due to mis-configured CMake config; fixed dbus server CMake config. Once built, the servers werent at the paths relative to the test binaries that were given in the test source files, because the test binary was in the test/ sub-directory. The dbus test just needed a ../ on its path; the qprocess one also needed its path wrapped in QFINDTESTDATA(), and a ".exe" suffix on MS. Pick-to: 6.2 6.1 5.15 Task-number: QTBUG-91713 Change-Id: I5ace23a5815575bbf88ea88e0b16afc7b8ba6a08 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'tests/benchmarks/corelib')
-rw-r--r--tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp b/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp
index 7077ec631a..0bc0332c6f 100644
--- a/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp
+++ b/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp
@@ -1,6 +1,6 @@
/****************************************************************************
**
-** Copyright (C) 2020 The Qt Company Ltd.
+** Copyright (C) 2021 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of the test suite of the Qt Toolkit.
@@ -40,10 +40,16 @@ private slots:
void echoTest_performance();
};
+#ifdef Q_OS_WIN
+# define EXE ".exe"
+#else
+# define EXE ""
+#endif
+
void tst_QProcess::echoTest_performance()
{
QProcess process;
- process.start("testProcessLoopback/testProcessLoopback");
+ process.start(QFINDTESTDATA("../testProcessLoopback/testProcessLoopback" EXE));
QByteArray array;
array.resize(1024 * 1024);