selftest: Disable NSLog/CFLog output to stderr
Ideally we want to catch if any of our selftests produce errors or warnings from system frameworks that are out fault, but in this case the warning does not seem to be something we can do anything about. The "+[IMKClient subclass]: chose IMKClient_Legacy" warning is logged via NSLog, so as a workaround we disable NSLog/CFLog output to stderr. Change-Id: I17b6b83844c4160aa5980d954b70f2582ff94da5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit 493fa52e135f73c1496715bb45602d9a4da1ade4) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
84cd298084
commit
f5e0d2e879
@ -959,6 +959,13 @@ static QProcessEnvironment testEnvironment()
|
||||
// Avoid the warning from QCoreApplication
|
||||
environment.insert("LC_ALL", "en_US.UTF-8");
|
||||
#endif
|
||||
|
||||
#if defined(Q_OS_MACOS)
|
||||
// Work around system framework spamming logs with
|
||||
// "+[IMKClient subclass]: chose IMKClient_Legacy"
|
||||
if (QOperatingSystemVersion::current() >= QOperatingSystemVersion::MacOSSequoia)
|
||||
environment.insert("CFLOG_FORCE_DISABLE_STDERR", "1");
|
||||
#endif
|
||||
}
|
||||
return environment;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user