forked from qt-creator/qt-creator
AutoTest: Support messages from death tests
Do not omit messages from death tests as they can be essential to figure out what went wrong. Fixes: QTCREATORBUG-25888 Change-Id: I30bc9856ae952dc30f4002a5bbc98245a524fae7 Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -64,6 +64,7 @@ void GTestOutputReader::processOutputLine(const QByteArray &outputLine)
|
|||||||
static const QRegularExpression newTestSetStarts("^\\[ RUN \\] (.*)$");
|
static const QRegularExpression newTestSetStarts("^\\[ RUN \\] (.*)$");
|
||||||
static const QRegularExpression testSetSuccess("^\\[ OK \\] (.*) \\((.*)\\)$");
|
static const QRegularExpression testSetSuccess("^\\[ OK \\] (.*) \\((.*)\\)$");
|
||||||
static const QRegularExpression testSetFail("^\\[ FAILED \\] (.*) \\((\\d+ ms)\\)$");
|
static const QRegularExpression testSetFail("^\\[ FAILED \\] (.*) \\((\\d+ ms)\\)$");
|
||||||
|
static const QRegularExpression testDeath("^\\[ DEATH \\] (.*)$");
|
||||||
static const QRegularExpression testSetSkipped("^\\[ SKIPPED \\] (.*) \\((\\d+ ms)\\)$");
|
static const QRegularExpression testSetSkipped("^\\[ SKIPPED \\] (.*) \\((\\d+ ms)\\)$");
|
||||||
static const QRegularExpression disabledTests("^ YOU HAVE (\\d+) DISABLED TESTS?$");
|
static const QRegularExpression disabledTests("^ YOU HAVE (\\d+) DISABLED TESTS?$");
|
||||||
static const QRegularExpression iterations("^Repeating all tests "
|
static const QRegularExpression iterations("^Repeating all tests "
|
||||||
@@ -182,6 +183,9 @@ void GTestOutputReader::processOutputLine(const QByteArray &outputLine)
|
|||||||
testResult->setFileName(file);
|
testResult->setFileName(file);
|
||||||
testResult->setDescription(match.captured(4));
|
testResult->setDescription(match.captured(4));
|
||||||
reportResult(testResult);
|
reportResult(testResult);
|
||||||
|
} else if (ExactMatch match = testDeath.match(line)) {
|
||||||
|
m_description.append(line);
|
||||||
|
m_description.append('\n');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user