summaryrefslogtreecommitdiffstats
path: root/src/testlib/qtestcase.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/testlib/qtestcase.cpp')
-rw-r--r--src/testlib/qtestcase.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/testlib/qtestcase.cpp b/src/testlib/qtestcase.cpp
index 05d1592a60..e5dd0d694a 100644
--- a/src/testlib/qtestcase.cpp
+++ b/src/testlib/qtestcase.cpp
@@ -1294,8 +1294,13 @@ void TestMethods::invokeTests(QObject *testObject) const
m_initTestCaseDataMethod.invoke(testObject, Qt::DirectConnection);
QScopedPointer<WatchDog> watchDog;
- if (!debuggerPresent())
+ if (!debuggerPresent()
+#ifdef QTESTLIB_USE_VALGRIND
+ && QBenchmarkGlobalData::current->mode() != QBenchmarkGlobalData::CallgrindChildProcess
+#endif
+ ) {
watchDog.reset(new WatchDog);
+ }
if (!QTestResult::skipCurrentTest() && !QTest::currentTestFailed()) {
if (m_initTestCaseMethod.isValid())