diff options
author | Jarek Kobus <jaroslaw.kobus@qt.io> | 2020-07-06 16:15:23 +0200 |
---|---|---|
committer | Jarek Kobus <jaroslaw.kobus@qt.io> | 2020-07-07 11:48:45 +0200 |
commit | 989fca660c3556fa957ed9a3f7cd3b948a4166a2 (patch) | |
tree | 8479b302afd3458cd2583dffc9e5dc52e512d9a1 /tests/auto/corelib/global | |
parent | d33655a9531b750e1574742ff575f871c19ed808 (diff) |
Use QList instead of QVector in corelib tests
Task-number: QTBUG-84469
Change-Id: Ic80fde5517aed363f17d0da55cadcc958c3c8895
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'tests/auto/corelib/global')
-rw-r--r-- | tests/auto/corelib/global/qglobal/tst_qglobal.cpp | 4 | ||||
-rw-r--r-- | tests/auto/corelib/global/qhooks/tst_qhooks.cpp | 2 | ||||
-rw-r--r-- | tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/tests/auto/corelib/global/qglobal/tst_qglobal.cpp b/tests/auto/corelib/global/qglobal/tst_qglobal.cpp index 4cfbdbde37..3c4bd3840e 100644 --- a/tests/auto/corelib/global/qglobal/tst_qglobal.cpp +++ b/tests/auto/corelib/global/qglobal/tst_qglobal.cpp @@ -93,7 +93,7 @@ void tst_QGlobal::qIsNull() void tst_QGlobal::for_each() { - QVector<int> list; + QList<int> list; list << 0 << 1 << 2 << 3 << 4 << 5; int counter = 0; @@ -112,7 +112,7 @@ void tst_QGlobal::for_each() // check whether we can pass a constructor as container argument counter = 0; - foreach (int i, QVector<int>(list)) { + foreach (int i, QList<int>(list)) { QCOMPARE(i, counter++); } QCOMPARE(counter, list.count()); diff --git a/tests/auto/corelib/global/qhooks/tst_qhooks.cpp b/tests/auto/corelib/global/qhooks/tst_qhooks.cpp index 5fa7566e86..c06b9e7e3d 100644 --- a/tests/auto/corelib/global/qhooks/tst_qhooks.cpp +++ b/tests/auto/corelib/global/qhooks/tst_qhooks.cpp @@ -81,7 +81,7 @@ void tst_QHooks::testAddRemoveObject() QCOMPARE(objectCount, 0); } -static QVector<QString> hookOrder; +static QList<QString> hookOrder; static QHooks::AddQObjectCallback existingAddHook = 0; static QHooks::RemoveQObjectCallback existingRemoveHook = 0; diff --git a/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp b/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp index 1c6e013adb..da0accad69 100644 --- a/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp +++ b/tests/auto/corelib/global/qrandomgenerator/tst_qrandomgenerator.cpp @@ -27,9 +27,9 @@ ****************************************************************************/ #include <QtTest> +#include <qlist.h> #include <qobject.h> #include <qrandom.h> -#include <qvector.h> #include <private/qrandom_p.h> #include <algorithm> @@ -621,7 +621,7 @@ void tst_QRandomGenerator::boundedQuality() { // test the quality of the generator - QVector<quint32> buffer(BufferCount, 0xcdcdcdcd); + QList<quint32> buffer(BufferCount, 0xcdcdcdcd); generate(buffer.begin(), buffer.end(), [&] { return rng.bounded(Bound); }); for (quint32 value : qAsConst(buffer)) { |