From 0be620ac58d43d2ad977944682b24ef1df3c21e0 Mon Sep 17 00:00:00 2001 From: Maurice Kalinowski Date: Thu, 22 Sep 2016 15:01:55 +0200 Subject: Fix test for targets without process support There is no need to switch to the current directory, when there is no process support. This also fixes running the test on sandboxed target platforms. Change-Id: I25fabb8b22d3510062a012884eb1eaab682901d3 Reviewed-by: Oliver Wolff --- tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp index bfa15744c2..b1ec94403a 100644 --- a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp +++ b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp @@ -73,8 +73,10 @@ void tst_QClipboard::cleanupTestCase() void tst_QClipboard::init() { +#ifndef QT_NO_PROCESS const QString testdataDir = QFileInfo(QFINDTESTDATA("copier")).absolutePath(); QVERIFY2(QDir::setCurrent(testdataDir), qPrintable("Could not chdir to " + testdataDir)); +#endif } Q_DECLARE_METATYPE(QClipboard::Mode) -- cgit v1.2.3