diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2015-12-13 20:12:15 +0100 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2015-12-13 20:12:15 +0100 |
commit | 03f91093dcfd8c7adb3b1ddabbf006ca8e0586a1 (patch) | |
tree | 8f84eebd41d217aa7ec0618ca4ee126d2e38966c /tests/clientapitest.cpp | |
parent | 1aa82ab9cfacca1ee9af9f9137caeede55f89230 (diff) | |
download | sink-03f91093dcfd8c7adb3b1ddabbf006ca8e0586a1.tar.gz sink-03f91093dcfd8c7adb3b1ddabbf006ca8e0586a1.zip |
Ensure we process the query also if no resource is available.
Diffstat (limited to 'tests/clientapitest.cpp')
-rw-r--r-- | tests/clientapitest.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/clientapitest.cpp b/tests/clientapitest.cpp index 5777e68..3a088f8 100644 --- a/tests/clientapitest.cpp +++ b/tests/clientapitest.cpp | |||
@@ -103,6 +103,16 @@ private Q_SLOTS: | |||
103 | QCOMPARE(model->rowCount(QModelIndex()), 1); | 103 | QCOMPARE(model->rowCount(QModelIndex()), 1); |
104 | } | 104 | } |
105 | 105 | ||
106 | void testLoadWithoutResource() | ||
107 | { | ||
108 | Akonadi2::Query query; | ||
109 | query.resources << "nonexisting.resource"; | ||
110 | query.liveQuery = false; | ||
111 | |||
112 | auto model = Akonadi2::Store::loadModel<Akonadi2::ApplicationDomain::Event>(query); | ||
113 | QTRY_VERIFY(model->data(QModelIndex(), Akonadi2::Store::ChildrenFetchedRole).toBool()); | ||
114 | } | ||
115 | |||
106 | //TODO: This test doesn't belong to this testsuite | 116 | //TODO: This test doesn't belong to this testsuite |
107 | void resourceManagement() | 117 | void resourceManagement() |
108 | { | 118 | { |