diff options
author | Edward Welbourne <edward.welbourne@qt.io> | 2020-02-25 17:18:29 +0100 |
---|---|---|
committer | Edward Welbourne <edward.welbourne@qt.io> | 2020-02-28 15:37:11 +0100 |
commit | 00f0863cbe7236742403a591b6409e480402cddf (patch) | |
tree | 3a3d29b0a20a3e31ad0cb56a1109005c2ced2ad2 /tests/auto/corelib/io | |
parent | 8c613ed74bf37573ca6c2d93e5bb77e0695ba953 (diff) |
Core: Use Qt::SplitBehavior in preference to QString::SplitBehavior
The Qt version was added in 5.14 "for use as eventual replacement for
QString::SplitBehavior." Move another step closer to that goal.
Change-Id: I446f9ddc8f8de4a0b79b09edb44f7c1496fbc33f
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/auto/corelib/io')
-rw-r--r-- | tests/auto/corelib/io/qdir/tst_qdir.cpp | 4 | ||||
-rw-r--r-- | tests/auto/corelib/io/qprocess/tst_qprocess.cpp | 4 | ||||
-rw-r--r-- | tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/tests/auto/corelib/io/qdir/tst_qdir.cpp b/tests/auto/corelib/io/qdir/tst_qdir.cpp index a6775ec2b6..1162fb31e4 100644 --- a/tests/auto/corelib/io/qdir/tst_qdir.cpp +++ b/tests/auto/corelib/io/qdir/tst_qdir.cpp @@ -1786,9 +1786,9 @@ void tst_QDir::searchPaths() { QFETCH(QString, filename); QFETCH(QString, searchPathPrefixes); - QStringList searchPathPrefixList = searchPathPrefixes.split(";", QString::SkipEmptyParts); + QStringList searchPathPrefixList = searchPathPrefixes.split(";", Qt::SkipEmptyParts); QFETCH(QString, searchPaths); - QStringList searchPathsList = searchPaths.split(";", QString::SkipEmptyParts); + QStringList searchPathsList = searchPaths.split(";", Qt::SkipEmptyParts); QFETCH(QString, expectedAbsolutePath); bool exists = !expectedAbsolutePath.isEmpty(); diff --git a/tests/auto/corelib/io/qprocess/tst_qprocess.cpp b/tests/auto/corelib/io/qprocess/tst_qprocess.cpp index e799369c8a..3de1bef789 100644 --- a/tests/auto/corelib/io/qprocess/tst_qprocess.cpp +++ b/tests/auto/corelib/io/qprocess/tst_qprocess.cpp @@ -2439,7 +2439,7 @@ void tst_QProcess::finishProcessBeforeReadingDone() QVERIFY(process.waitForStarted()); loop.exec(); QStringList lines = QString::fromLocal8Bit(process.readAllStandardOutput()).split( - QRegExp(QStringLiteral("[\r\n]")), QString::SkipEmptyParts); + QRegExp(QStringLiteral("[\r\n]")), Qt::SkipEmptyParts); QVERIFY(!lines.isEmpty()); QCOMPARE(lines.last(), QStringLiteral("10239 -this is a number")); QCOMPARE(process.exitStatus(), QProcess::NormalExit); @@ -2671,7 +2671,7 @@ void tst_QProcess::finishProcessBeforeReadingDone_deprecated() QVERIFY(process.waitForStarted()); loop.exec(); QStringList lines = QString::fromLocal8Bit(process.readAllStandardOutput()).split( - QRegExp(QStringLiteral("[\r\n]")), QString::SkipEmptyParts); + QRegExp(QStringLiteral("[\r\n]")), Qt::SkipEmptyParts); QVERIFY(!lines.isEmpty()); QCOMPARE(lines.last(), QStringLiteral("10239 -this is a number")); QCOMPARE(process.exitStatus(), QProcess::NormalExit); diff --git a/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp b/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp index dae4e66106..d0fbdb7a2a 100644 --- a/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp +++ b/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp @@ -360,7 +360,7 @@ static inline QFileInfo findSh() QLatin1String sh("/sh"); QByteArray pEnv = qgetenv("PATH"); const QLatin1Char pathSep(':'); - const QStringList rawPaths = QString::fromLocal8Bit(pEnv.constData()).split(pathSep, QString::SkipEmptyParts); + const QStringList rawPaths = QString::fromLocal8Bit(pEnv.constData()).split(pathSep, Qt::SkipEmptyParts); foreach (const QString &path, rawPaths) { if (QFile::exists(path + sh)) return path + sh; |