diff options
author | Lars Knoll <lars.knoll@qt.io> | 2020-08-24 17:49:44 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2020-08-24 21:37:09 +0200 |
commit | 1fcc136e74f85a6eeac6508b7138a375e8ced1c5 (patch) | |
tree | 33f974b73fa3c2d269b0183fb46109fbd50a3909 /tests | |
parent | c3ca1f972e402281d3ec42498d3051767449a41b (diff) |
Remove deprecated functionality
Required to get the module to compile against a new qtbase
Change-Id: I4f7c6f10c94da640c1f1eec0bbbbc22bbd7cb2ea
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/qhelpenginecore/tst_qhelpenginecore.cpp | 23 | ||||
-rw-r--r-- | tests/auto/qhelpindexmodel/tst_qhelpindexmodel.cpp | 46 |
2 files changed, 0 insertions, 69 deletions
diff --git a/tests/auto/qhelpenginecore/tst_qhelpenginecore.cpp b/tests/auto/qhelpenginecore/tst_qhelpenginecore.cpp index ddadda10b..773a2bcfb 100644 --- a/tests/auto/qhelpenginecore/tst_qhelpenginecore.cpp +++ b/tests/auto/qhelpenginecore/tst_qhelpenginecore.cpp @@ -64,8 +64,6 @@ private slots: void files(); void fileData(); - void linksForIdentifier(); - void customValue(); void setCustomValue(); void removeCustomValue(); @@ -377,27 +375,6 @@ void tst_QHelpEngineCore::fileData() QCOMPARE(s.readAll(), ts.readAll()); } -void tst_QHelpEngineCore::linksForIdentifier() -{ - QHelpEngineCore help(m_colFile, 0); - QCOMPARE(help.setupData(), true); - QMap<QString, QUrl> map; - map = help.linksForIdentifier("Test::foo"); - QCOMPARE(map.contains("Test Manual"), true); - QCOMPARE(map.count(), 1); - QCOMPARE(map.value("Test Manual"), - QUrl("qthelp://trolltech.com.1.0.0.test/testFolder/test.html#foo")); - - help.setCurrentFilter("Custom Filter 2"); - map = help.linksForIdentifier("People::newton"); - QCOMPARE(map.isEmpty(), true); - map = help.linksForIdentifier("Fancy::foobar"); - QCOMPARE(map.contains("Fancy"), true); - QCOMPARE(map.count(), 1); - QCOMPARE(map.value("Fancy"), - QUrl("qthelp://trolltech.com.1.0.0.test/testFolder/fancy.html#foobar")); -} - void tst_QHelpEngineCore::customValue() { QHelpEngineCore help(m_colFile, 0); diff --git a/tests/auto/qhelpindexmodel/tst_qhelpindexmodel.cpp b/tests/auto/qhelpindexmodel/tst_qhelpindexmodel.cpp index d304c3f3b..358be9956 100644 --- a/tests/auto/qhelpindexmodel/tst_qhelpindexmodel.cpp +++ b/tests/auto/qhelpindexmodel/tst_qhelpindexmodel.cpp @@ -76,7 +76,6 @@ private slots: void setupIndex(); void filter(); - void linksForIndex(); private: QString m_colFile; @@ -152,50 +151,5 @@ void tst_QHelpIndexModel::filter() QCOMPARE(m->stringList().count(), 11); } -void tst_QHelpIndexModel::linksForIndex() -{ - QHelpEngine h(m_colFile, 0); - QHelpIndexModel *m = h.indexModel(); - SignalWaiter w; - connect(m, SIGNAL(indexCreated()), - &w, SLOT(stopWaiting())); - w.start(); - h.setupData(); - int i = 0; - while (w.isRunning() && i++ < 10) - QTest::qWait(500); - - QCOMPARE(h.currentFilter(), QString("unfiltered")); - QMap<QString, QUrl> map; - map = m->linksForKeyword("foo"); - QCOMPARE(map.count(), 2); - QCOMPARE(map.contains("Test Manual"), true); - QCOMPARE(map.value("Test Manual"), - QUrl("qthelp://trolltech.com.1-0-0.test/testFolder/test.html#foo")); - - QCOMPARE(map.contains("Fancy"), true); - QCOMPARE(map.value("Fancy"), - QUrl("qthelp://trolltech.com.1-0-0.test/testFolder/fancy.html#foo")); - - map = m->linksForKeyword("foobar"); - QCOMPARE(map.count(), 1); - QCOMPARE(map.contains("Fancy"), true); - - map = m->linksForKeyword("notexisting"); - QCOMPARE(map.count(), 0); - - w.start(); - h.setCurrentFilter("Custom Filter 1"); - i = 0; - while (w.isRunning() && i++ < 10) - QTest::qWait(500); - - map = m->linksForKeyword("foo"); - QCOMPARE(map.count(), 1); - QCOMPARE(map.contains("Test Manual"), true); - QCOMPARE(map.value("Test Manual"), - QUrl("qthelp://trolltech.com.1-0-0.test/testFolder/test.html#foo")); -} - QTEST_MAIN(tst_QHelpIndexModel) #include "tst_qhelpindexmodel.moc" |