forked from qt-creator/qt-creator
OutputFormatter: Do not ignore DebugFormat
On Windows applications may print to the Windows internal debug console. This output is retrieved and passed around as DebugFormat as it is impossible to guess whether stdout or stderr had been used when printing. But output in DebugFormat had been ignored so far - fix this and handle this as inside the Qt test parser. Fixes: QTCREATORBUG-24560 Change-Id: Ic5e3723c3e3e47556264e4c5cf719706ee7eaf1c Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -329,7 +329,9 @@ OutputLineParser::Result OutputFormatter::handleMessage(const QString &text, Out
|
|||||||
QList<OutputLineParser *> &involvedParsers)
|
QList<OutputLineParser *> &involvedParsers)
|
||||||
{
|
{
|
||||||
// We only invoke the line parsers for stdout and stderr
|
// We only invoke the line parsers for stdout and stderr
|
||||||
if (format != StdOutFormat && format != StdErrFormat)
|
// Bad: on Windows we may get stdout and stdErr only as DebugFormat as e.g. GUI applications
|
||||||
|
// print them Windows-internal and we retrieve this separately
|
||||||
|
if (format != StdOutFormat && format != StdErrFormat && format != DebugFormat)
|
||||||
return OutputLineParser::Status::NotHandled;
|
return OutputLineParser::Status::NotHandled;
|
||||||
const OutputLineParser * const oldNextParser = d->nextParser;
|
const OutputLineParser * const oldNextParser = d->nextParser;
|
||||||
if (d->nextParser) {
|
if (d->nextParser) {
|
||||||
|
@@ -49,7 +49,7 @@ namespace Internal {
|
|||||||
|
|
||||||
OutputLineParser::Result QtTestParser::handleLine(const QString &line, OutputFormat type)
|
OutputLineParser::Result QtTestParser::handleLine(const QString &line, OutputFormat type)
|
||||||
{
|
{
|
||||||
if (type != StdOutFormat)
|
if (type != StdOutFormat && type != DebugFormat)
|
||||||
return Status::NotHandled;
|
return Status::NotHandled;
|
||||||
|
|
||||||
const QString theLine = rightTrimmed(line);
|
const QString theLine = rightTrimmed(line);
|
||||||
|
Reference in New Issue
Block a user