Fix the manual test

This commit is contained in:
Luca Beltrame 2020-08-19 16:35:51 +02:00
parent c6a936bde8
commit dd7f10cb60
Signed by: einar
GPG key ID: 4707F46E9EC72DEC

View file

@ -31,7 +31,7 @@ DanbooruServiceTest::DanbooruServiceTest(QUrl boardUrl, Danbooru::ApiType type):
auto cache = new KImageCache("test-data", 48000000);
cache->clear();
cache->setPixmapCaching(true);
switch(type) {
case Danbooru::MoeBooru:
m_service = new MoebooruService(boardUrl);
@ -41,13 +41,12 @@ DanbooruServiceTest::DanbooruServiceTest(QUrl boardUrl, Danbooru::ApiType type):
break;
default:
qDebug() << "Not implemented";
};
m_service->setParent(this);
m_service->setMaximumAllowedRating(Danbooru::Explicit);
m_service->setMaxPosts(2);
m_service->setImageCache(cache);
connect(m_service, &DanbooruServiceBase::postDownloaded, this, &DanbooruServiceTest::showPostData);
connect(m_service, &DanbooruServiceBase::poolDownloaded, this, &DanbooruServiceTest::showPoolData);
}