forked from qt-creator/qt-creator
AutoTest: Clear up and generalize
Instead of transforming forth and back the output try to handle the output once correctly and pass it line-wise around. This also ensures that we always get a single line when appending the output which will be necessary later on. Change-Id: I3e9c6db5f81172997dfe566eee9a86bfe2f17a1f Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -354,7 +354,7 @@ static QStringList extractFunctionInformation(const QString &testClassName,
|
||||
return result;
|
||||
}
|
||||
|
||||
void QtTestOutputReader::processPlainTextOutput(const QByteArray &outputLineWithNewLine)
|
||||
void QtTestOutputReader::processPlainTextOutput(const QByteArray &outputLine)
|
||||
{
|
||||
static const QRegularExpression start("^[*]{9} Start testing of (.*) [*]{9}$");
|
||||
static const QRegularExpression config("^Config: Using QtTest library (.*), "
|
||||
@@ -375,7 +375,7 @@ void QtTestOutputReader::processPlainTextOutput(const QByteArray &outputLineWith
|
||||
if (m_futureInterface.isCanceled())
|
||||
return;
|
||||
|
||||
const QString line = QString::fromUtf8(chopLineBreak(outputLineWithNewLine));
|
||||
const QString line = QString::fromUtf8(outputLine);
|
||||
QRegularExpressionMatch match;
|
||||
|
||||
auto hasMatch = [&match, line](const QRegularExpression ®ex) {
|
||||
|
||||
Reference in New Issue
Block a user