From 78722f6c6c89de6b0c49d9d6ce49db8506104aaf Mon Sep 17 00:00:00 2001
From: Jarek Kobus <jaroslaw.kobus@qt.io>
Date: Thu, 24 Aug 2017 17:41:39 +0200
Subject: [PATCH] Don't create unused IndexItemTable

Change-Id: I0fa1ea9a1b6b6d1b1da481880f7a620284456487
Reviewed-by: Karsten Heimrich <karsten.heimrich@qt.io>
---
 src/assistant/help/qhelpgenerator.cpp            | 3 ---
 tests/auto/qhelpgenerator/tst_qhelpgenerator.cpp | 6 ------
 2 files changed, 9 deletions(-)

diff --git a/src/assistant/help/qhelpgenerator.cpp b/src/assistant/help/qhelpgenerator.cpp
index c8722499e..d341a04de 100644
--- a/src/assistant/help/qhelpgenerator.cpp
+++ b/src/assistant/help/qhelpgenerator.cpp
@@ -311,9 +311,6 @@ bool QHelpGenerator::createTables()
                              "NamespaceId INTEGER, "
                              "FileId INTEGER, "
                              "Anchor TEXT )")
-            << QLatin1String("CREATE TABLE IndexItemTable ("
-                             "Id INTEGER, "
-                             "IndexId INTEGER )")
             << QLatin1String("CREATE TABLE IndexFilterTable ("
                              "FilterAttributeId INTEGER, "
                              "IndexId INTEGER )")
diff --git a/tests/auto/qhelpgenerator/tst_qhelpgenerator.cpp b/tests/auto/qhelpgenerator/tst_qhelpgenerator.cpp
index da7e03779..10cfff9ac 100644
--- a/tests/auto/qhelpgenerator/tst_qhelpgenerator.cpp
+++ b/tests/auto/qhelpgenerator/tst_qhelpgenerator.cpp
@@ -137,12 +137,6 @@ void tst_QHelpGenerator::checkIndices()
         || m_query->value(1).toString() != QLatin1String("foo"))
         QFAIL("Index Error!");
 
-    /*
-    m_query->exec("SELECT COUNT(DISTINCT Id) FROM IndexItemTable");
-    if (!m_query->next() || m_query->value(0).toInt() != 7)
-        QFAIL("Index Error!");
-    */
-
     m_query->exec("SELECT COUNT(a.Id) FROM IndexTable a, "
         "IndexFilterTable b, FilterAttributeTable c WHERE a.Id=b.IndexId "
         "AND b.FilterAttributeId=c.Id AND c.Name=\'filter2\'");
-- 
GitLab