From 59ad4465b1d36e3b69dbb6ed5ad8f2f406730591 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Fri, 3 Feb 2017 08:43:03 +0100 Subject: [PATCH] tst_uic: Update version regexp The pattern did not match double-digit version numbers like 5.10.0. Adapt it to better match the version number and use QRegularExpression. Change-Id: I2e25b247213cee6853bfeb27871c839135e3970f Reviewed-by: Jarek Kobus --- tests/auto/tools/uic/tst_uic.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/auto/tools/uic/tst_uic.cpp b/tests/auto/tools/uic/tst_uic.cpp index cf43cb02d38..85668c96d43 100644 --- a/tests/auto/tools/uic/tst_uic.cpp +++ b/tests/auto/tools/uic/tst_uic.cpp @@ -34,6 +34,7 @@ #include #include #include +#include #include class tst_uic : public QObject @@ -63,12 +64,12 @@ private: const QString m_command; QString m_baseline; QTemporaryDir m_generated; - QRegExp m_versionRegexp; + QRegularExpression m_versionRegexp; }; tst_uic::tst_uic() : m_command(QLibraryInfo::location(QLibraryInfo::BinariesPath) + QLatin1String("/uic")) - , m_versionRegexp(QLatin1String("Created by: Qt User Interface Compiler version [.\\d]{5,5}")) + , m_versionRegexp(QLatin1String("\\*\\* Created by: Qt User Interface Compiler version \\d{1,2}\\.\\d{1,2}\\.\\d{1,2}")) { }