Fix some warnings in tests.
authorFriedemann Kleint <Friedemann.Kleint@nokia.com>
Mon, 27 Aug 2012 07:27:04 +0000 (09:27 +0200)
committerQt by Nokia <qt-info@nokia.com>
Tue, 28 Aug 2012 15:07:15 +0000 (17:07 +0200)
- Unused variables
- Signed/Unsigned comparisons.

Change-Id: I0f4cc92a8366ad501d703d19c3358ac24db47270
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
tests/auto/other/modeltest/tst_modeltest.cpp
tests/auto/widgets/kernel/qsizepolicy/tst_qsizepolicy.cpp

index 33eb411..7960ad1 100644 (file)
@@ -258,8 +258,8 @@ public slots:
     void checkPersistent()
     {
         for (int row = 0; row < m_persistentProxyIndexes.size(); ++row) {
-            QModelIndex updatedProxy = m_persistentProxyIndexes.at(row);
-            QModelIndex updatedSource = m_persistentSourceIndexes.at(row);
+            m_persistentProxyIndexes.at(row);
+            m_persistentSourceIndexes.at(row);
         }
         for (int row = 0; row < m_persistentProxyIndexes.size(); ++row) {
             QModelIndex updatedProxy = m_persistentProxyIndexes.at(row);
index 7108c9d..2999b00 100644 (file)
@@ -96,7 +96,7 @@ void tst_QSizePolicy::getSetCheck()
             QSizePolicy::ToolButton
         };
 
-#define ITEMCOUNT(arr) sizeof(arr)/sizeof(arr[0])
+#define ITEMCOUNT(arr) int(sizeof(arr)/sizeof(arr[0]))
         QSizePolicy sp, oldsp;
 #ifdef GENERATE_BASELINE
         QFile out(QString::fromAscii("qsizepolicy-Qt%1%2.txt").arg((QT_VERSION >> 16) & 0xff).arg((QT_VERSION) >> 8 & 0xff));