1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 01:22:10 +01:00

autotests: be more chatty during test

This particular test fails for me: I apparently have some qupzilla
URLs on speed-dial that show up in the test, causing it to fail.
This commit is contained in:
Adriaan de Groot 2022-01-18 16:26:59 +01:00
parent 12aa99ad50
commit a706713900

View File

@ -34,6 +34,19 @@ void QmlTopSitesApiTest::testTopSites()
{ {
mApp->plugins()->speedDial()->addPage(QUrl("https://example.com"), "Example Domain"); mApp->plugins()->speedDial()->addPage(QUrl("https://example.com"), "Example Domain");
auto list = m_testHelper.evaluate("Falkon.TopSites.get()").toVariant().toList(); auto list = m_testHelper.evaluate("Falkon.TopSites.get()").toVariant().toList();
qDebug() << "Top sites list size=" << list.length();
for( const auto& site : list )
{
QObject* object = qvariant_cast<QObject*>(site);
if (object)
{
qDebug() << ".." << object->property("title") << object->property("url");
}
else
{
qDebug() << ".." << site;
}
}
QCOMPARE(list.length(), 1); QCOMPARE(list.length(), 1);
QObject* object = qvariant_cast<QObject*>(list.at(0)); QObject* object = qvariant_cast<QObject*>(list.at(0));
QVERIFY(object); QVERIFY(object);