diff options
author | Edward Welbourne <edward.welbourne@qt.io> | 2022-08-01 16:56:46 +0200 |
---|---|---|
committer | Edward Welbourne <edward.welbourne@qt.io> | 2022-09-22 17:34:51 +0200 |
commit | abab3c5dadd7fb80c2807f061e4d6aa7724c78c8 (patch) | |
tree | ffec57b4912b8f52e43e9d5eeb33890e26c9aa40 /src | |
parent | 16f5132b2184fc62b2959bd4b13245a72c97042d (diff) |
Fix error in TAP test logger's regex to recognize QVERIFY() output
The regex used a greedy .+ to match an actual dot and a space,
preceding an open parenthesis, with the result that if the message
contained any parentheses that .+ swallowed everything up to the last
of them. Correct the regex so that recently-added tests' error
messages show up correctly.
Change-Id: I6e52c9b2a6e7959335fcddbb4266f65b589eba68
Reviewed-by: Jason McDonald <macadder1@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/testlib/qtaptestlogger.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/testlib/qtaptestlogger.cpp b/src/testlib/qtaptestlogger.cpp index b6fa4295bc..2c87c15d6c 100644 --- a/src/testlib/qtaptestlogger.cpp +++ b/src/testlib/qtaptestlogger.cpp @@ -292,7 +292,7 @@ void QTapTestLogger::addIncident(IncidentTypes type, const char *description, // the expected and actual values to the loggers (yet). static const QRegularExpression verifyRegex( u"^'(?<actualexpression>.*)' returned " - "(?<actual>\\w+).+\\((?<message>.*)\\)$"_s); + "(?<actual>\\w+)\\. \\((?<message>.*)\\)$"_s); static const QRegularExpression compareRegex( u"^(?<message>.*)\n" |