Minor adjustments to tests
This commit is contained in:
parent
15446c74ac
commit
3b28adb512
1 changed files with 4 additions and 3 deletions
|
@ -25,7 +25,7 @@
|
||||||
namespace Danbooru {
|
namespace Danbooru {
|
||||||
|
|
||||||
DanbooruServiceTest::DanbooruServiceTest(QUrl boardUrl, Danbooru::ApiType type):
|
DanbooruServiceTest::DanbooruServiceTest(QUrl boardUrl, Danbooru::ApiType type):
|
||||||
m_service(0),
|
m_service(nullptr),
|
||||||
m_label(new QLabel())
|
m_label(new QLabel())
|
||||||
{
|
{
|
||||||
auto cache = new KImageCache("test-data", 48000000);
|
auto cache = new KImageCache("test-data", 48000000);
|
||||||
|
@ -39,12 +39,13 @@ DanbooruServiceTest::DanbooruServiceTest(QUrl boardUrl, Danbooru::ApiType type):
|
||||||
case Danbooru::Danbooru:
|
case Danbooru::Danbooru:
|
||||||
m_service = new DanbooruService(boardUrl);
|
m_service = new DanbooruService(boardUrl);
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
qDebug() << "Not implemented";
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
qDebug() << m_service->apiType() << "type";
|
|
||||||
m_service->setParent(this);
|
m_service->setParent(this);
|
||||||
m_service->setMaximumAllowedRating(Danbooru::Questionable);
|
m_service->setMaximumAllowedRating(Danbooru::Explicit);
|
||||||
m_service->setMaxPosts(2);
|
m_service->setMaxPosts(2);
|
||||||
m_service->setImageCache(cache);
|
m_service->setImageCache(cache);
|
||||||
connect(m_service, &DanbooruServiceBase::postDownloaded, this, &DanbooruServiceTest::showPostData);
|
connect(m_service, &DanbooruServiceBase::postDownloaded, this, &DanbooruServiceTest::showPostData);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue