summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2020-03-30 13:33:31 +0200
committerLars Knoll <lars.knoll@qt.io>2020-03-31 15:28:23 +0200
commit7f267360f2220322d9a4bec921be651f51f83da4 (patch)
treeb948676c8b248343dcd111f09862bd59dd865026
parent2fda4cda22994466e3e1da028a7edeca657b4e7d (diff)
Port test to QRegularExpression
Change-Id: I4026fa2fa5da34974cdc37353e7ea5a8e8806033 Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
-rw-r--r--tests/auto/tools/moc/tst_moc.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/tools/moc/tst_moc.cpp b/tests/auto/tools/moc/tst_moc.cpp
index 221e741647..b701aa05a3 100644
--- a/tests/auto/tools/moc/tst_moc.cpp
+++ b/tests/auto/tools/moc/tst_moc.cpp
@@ -33,6 +33,7 @@
#include <qmetaobject.h>
#include <qjsondocument.h>
#include <qversionnumber.h>
+#include <qregularexpression.h>
#include "using-namespaces.h"
#include "assign-namespace.h"
@@ -2254,8 +2255,7 @@ void tst_Moc::warnings()
#ifdef Q_CC_MSVC
// for some reasons, moc compiled with MSVC uses a different output format
- QRegExp lineNumberRe(":(-?\\d+):");
- lineNumberRe.setMinimal(true);
+ QRegularExpression lineNumberRe(":(-?\\d+):", QRegularExpression::InvertedGreedinessOption);
expectedStdErr.replace(lineNumberRe, "(\\1):");
#endif