diff --git a/autotests/karchivetest.cpp b/autotests/karchivetest.cpp --- a/autotests/karchivetest.cpp +++ b/autotests/karchivetest.cpp @@ -29,6 +29,7 @@ #include #include #include +#include #ifndef Q_OS_WIN #include // symlink @@ -538,13 +539,13 @@ // This one was added with addLocalFile, so ignore mode. QString str = listing[14]; - str.replace(QRegExp(QStringLiteral("mode.*user=")), QStringLiteral("user=")); + str.replace(QRegularExpression(QStringLiteral("mode.*user=")), QStringLiteral("user=")); compareEntryWithTimestamp(str, QString("user=%1 group=%2 path=z/test3 type=file size=13").arg(owner).arg(group), creationTime); #ifndef Q_OS_WIN str = listing[15]; - str.replace(QRegExp(QStringLiteral("mode.*path=")), QStringLiteral("path=")); + str.replace(QRegularExpression(QStringLiteral("mode.*path=")), QStringLiteral("path=")); compareEntryWithTimestamp(str, QString("path=z/test3_symlink type=file size=0 symlink=test3"), creationTime); #endif @@ -1006,11 +1007,11 @@ QCOMPARE(listing[14], QString("mode=40777 path=z type=dir")); // This one was added with addLocalFile, so ignore mode QString str = listing[15]; - str.replace(QRegExp(QStringLiteral("mode.*path=")), QStringLiteral("path=")); + str.replace(QRegularExpression(QStringLiteral("mode.*path=")), QStringLiteral("path=")); QCOMPARE(str, QString("path=z/test3 type=file size=13")); #ifndef Q_OS_WIN str = listing[16]; - str.replace(QRegExp(QStringLiteral("mode.*path=")), QStringLiteral("path=")); + str.replace(QRegularExpression(QStringLiteral("mode.*path=")), QStringLiteral("path=")); QCOMPARE(str, QString("path=z/test3_symlink type=file size=5 symlink=test3")); #endif @@ -1397,11 +1398,11 @@ QCOMPARE(listing[13], QString("mode=40777 path=z type=dir")); // This one was added with addLocalFile, so ignore mode/user/group. QString str = listing[14]; - str.replace(QRegExp(QStringLiteral("mode.*path=")), QStringLiteral("path=")); + str.replace(QRegularExpression(QStringLiteral("mode.*path=")), QStringLiteral("path=")); QCOMPARE(str, QString("path=z/test3 type=file size=13")); #ifndef Q_OS_WIN str = listing[15]; - str.replace(QRegExp(QStringLiteral("mode.*path=")), QStringLiteral("path=")); + str.replace(QRegularExpression(QStringLiteral("mode.*path=")), QStringLiteral("path=")); QCOMPARE(str, QString("path=z/test3_symlink type=file size=0 symlink=test3")); #endif