diff options
author | Friedemann Kleint <Friedemann.Kleint@digia.com> | 2013-03-07 14:59:13 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-03-11 14:40:12 +0100 |
commit | 86ea7dad2fba0b7262e7f2c665a99324f9bc2f9f (patch) | |
tree | ea849631272d1aa8e31a0c8a92378b546306f453 | |
parent | c520a69f06317fb90d37324bf284ef9614cb5dbf (diff) |
Fix warnings about unused variables in tests (CLANG).
Change-Id: I29d4a41d2b6c4ac5c7b27930257c3853500325a1
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
4 files changed, 23 insertions, 28 deletions
diff --git a/tests/auto/declarative/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp b/tests/auto/declarative/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp index 903b3739..995c375a 100644 --- a/tests/auto/declarative/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp +++ b/tests/auto/declarative/qdeclarativedebugjs/tst_qdeclarativedebugjs.cpp @@ -133,10 +133,6 @@ private: class tst_QDeclarativeDebugJS : public QDeclarativeDataTest { Q_OBJECT -private: - QDeclarativeDebugConnection *m_conn; - QDeclarativeEngine *m_engine; - QJSDebugClient *m_client; private slots: void initTestCase(); diff --git a/tests/auto/declarative/qdeclarativedebugobservermode/tst_qdeclarativedebugobservermode.cpp b/tests/auto/declarative/qdeclarativedebugobservermode/tst_qdeclarativedebugobservermode.cpp index 83c2f21a..d97ae70d 100644 --- a/tests/auto/declarative/qdeclarativedebugobservermode/tst_qdeclarativedebugobservermode.cpp +++ b/tests/auto/declarative/qdeclarativedebugobservermode/tst_qdeclarativedebugobservermode.cpp @@ -117,10 +117,6 @@ private: class tst_QDeclarativeDebugObserverMode : public QDeclarativeDataTest { Q_OBJECT -private: - QDeclarativeDebugConnection *m_conn; - QDeclarativeEngine *m_engine; - QDeclarativeObserverModeClient *m_client; private slots: void initTestCase(); diff --git a/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp b/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp index 7795e026..f67cecdc 100644 --- a/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp +++ b/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp @@ -334,6 +334,8 @@ public: setFinished(true); } virtual qint64 readData(char* buffer, qint64 number) { + Q_UNUSED(buffer) + Q_UNUSED(number) return 0; } virtual void abort() { } @@ -348,6 +350,9 @@ public: } QNetworkReply *createRequest(Operation op, const QNetworkRequest & req, QIODevice * outgoingData = 0) { + Q_UNUSED(op) + Q_UNUSED(req) + Q_UNUSED(outgoingData) return new MyReply; } }; @@ -356,7 +361,7 @@ class MyFactory : public QDeclarativeNetworkAccessManagerFactory { public: QNetworkAccessManager *create(QObject *parent) { - return new MyManager; + return new MyManager(parent); } }; diff --git a/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp b/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp index cd8c5aed..8815dbfb 100644 --- a/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp +++ b/tests/auto/declarative/qdeclarativepathview/tst_qdeclarativepathview.cpp @@ -615,45 +615,44 @@ void tst_QDeclarativePathView::moveModel_data() QTest::addColumn<int>("from"); QTest::addColumn<int>("to"); QTest::addColumn<int>("count"); - QTest::addColumn<qreal>("offset"); QTest::addColumn<int>("currentIndex"); // We have 8 items, with currentIndex == 4 QTest::newRow("move after current") - << int(QDeclarativePathView::StrictlyEnforceRange) << 5 << 6 << 1 << 4. << 4; + << int(QDeclarativePathView::StrictlyEnforceRange) << 5 << 6 << 1 << 4; QTest::newRow("move before current") - << int(QDeclarativePathView::StrictlyEnforceRange) << 2 << 3 << 1 << 4. << 4; + << int(QDeclarativePathView::StrictlyEnforceRange) << 2 << 3 << 1 << 4; QTest::newRow("move before current to after") - << int(QDeclarativePathView::StrictlyEnforceRange) << 2 << 6 << 1 << 5. << 3; + << int(QDeclarativePathView::StrictlyEnforceRange) << 2 << 6 << 1 << 3; QTest::newRow("move multiple after current") - << int(QDeclarativePathView::StrictlyEnforceRange) << 5 << 6 << 2 << 4. << 4; + << int(QDeclarativePathView::StrictlyEnforceRange) << 5 << 6 << 2 << 4; QTest::newRow("move multiple before current") - << int(QDeclarativePathView::StrictlyEnforceRange) << 0 << 1 << 2 << 4. << 4; + << int(QDeclarativePathView::StrictlyEnforceRange) << 0 << 1 << 2 << 4; QTest::newRow("move before current to end") - << int(QDeclarativePathView::StrictlyEnforceRange) << 2 << 7 << 1 << 5. << 3; + << int(QDeclarativePathView::StrictlyEnforceRange) << 2 << 7 << 1 << 3; QTest::newRow("move last to beginning") - << int(QDeclarativePathView::StrictlyEnforceRange) << 7 << 0 << 1 << 3. << 5; + << int(QDeclarativePathView::StrictlyEnforceRange) << 7 << 0 << 1 << 5; QTest::newRow("move current") - << int(QDeclarativePathView::StrictlyEnforceRange) << 4 << 6 << 1 << 2. << 6; + << int(QDeclarativePathView::StrictlyEnforceRange) << 4 << 6 << 1 << 6; QTest::newRow("no range - move after current") - << int(QDeclarativePathView::NoHighlightRange) << 5 << 6 << 1 << 4. << 4; + << int(QDeclarativePathView::NoHighlightRange) << 5 << 6 << 1 << 4; QTest::newRow("no range - move before current") - << int(QDeclarativePathView::NoHighlightRange) << 2 << 3 << 1 << 4. << 4; + << int(QDeclarativePathView::NoHighlightRange) << 2 << 3 << 1 << 4; QTest::newRow("no range - move before current to after") - << int(QDeclarativePathView::NoHighlightRange) << 2 << 6 << 1 << 5. << 3; + << int(QDeclarativePathView::NoHighlightRange) << 2 << 6 << 1 << 3; QTest::newRow("no range - move multiple after current") - << int(QDeclarativePathView::NoHighlightRange) << 5 << 6 << 2 << 4. << 4; + << int(QDeclarativePathView::NoHighlightRange) << 5 << 6 << 2 << 4; QTest::newRow("no range - move multiple before current") - << int(QDeclarativePathView::NoHighlightRange) << 0 << 1 << 2 << 4. << 4; + << int(QDeclarativePathView::NoHighlightRange) << 0 << 1 << 2 << 4; QTest::newRow("no range - move before current to end") - << int(QDeclarativePathView::NoHighlightRange) << 2 << 7 << 1 << 5. << 3; + << int(QDeclarativePathView::NoHighlightRange) << 2 << 7 << 1 << 3; QTest::newRow("no range - move last to beginning") - << int(QDeclarativePathView::NoHighlightRange) << 7 << 0 << 1 << 3. << 5; + << int(QDeclarativePathView::NoHighlightRange) << 7 << 0 << 1 << 5; QTest::newRow("no range - move current") - << int(QDeclarativePathView::NoHighlightRange) << 4 << 6 << 1 << 4. << 6; + << int(QDeclarativePathView::NoHighlightRange) << 4 << 6 << 1 << 6; QTest::newRow("no range - move multiple incl. current") - << int(QDeclarativePathView::NoHighlightRange) << 0 << 1 << 5 << 4. << 5; + << int(QDeclarativePathView::NoHighlightRange) << 0 << 1 << 5 << 5; } void tst_QDeclarativePathView::moveModel() @@ -662,7 +661,6 @@ void tst_QDeclarativePathView::moveModel() QFETCH(int, from); QFETCH(int, to); QFETCH(int, count); - QFETCH(qreal, offset); QFETCH(int, currentIndex); QDeclarativeView *window = createView(); |