summaryrefslogtreecommitdiffstats
path: root/tests/auto/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/tools')
-rw-r--r--tests/auto/tools/moc/tst_moc.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/auto/tools/moc/tst_moc.cpp b/tests/auto/tools/moc/tst_moc.cpp
index 3cd2f1f936..e0179b393b 100644
--- a/tests/auto/tools/moc/tst_moc.cpp
+++ b/tests/auto/tools/moc/tst_moc.cpp
@@ -1734,6 +1734,11 @@ void tst_Moc::warnings()
#endif
QProcess proc;
+
+ QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
+ env.insert("QT_MESSAGE_PATTERN", "no qDebug or qWarning please");
+ proc.setProcessEnvironment(env);
+
proc.start("moc", args);
QVERIFY(proc.waitForStarted());