summaryrefslogtreecommitdiffstats
path: root/tests/storagetest.cpp
diff options
context:
space:
mode:
authorChristian Mollekopf <chrigi_1@fastmail.fm>2015-08-23 13:02:04 +0200
committerChristian Mollekopf <chrigi_1@fastmail.fm>2015-08-23 13:03:50 +0200
commit4141b5e8e6296ca8ab94553e27257f8c2b107461 (patch)
tree02c5a45a7e6736c24d76dbb24eeb468f1ced11d9 /tests/storagetest.cpp
parent6746247a49f09287ae4924c5c3df791f9bf61cbc (diff)
downloadsink-4141b5e8e6296ca8ab94553e27257f8c2b107461.tar.gz
sink-4141b5e8e6296ca8ab94553e27257f8c2b107461.zip
Less noise and better error handling.
Trying to read from non-existant databases no longer prints error messages.
Diffstat (limited to 'tests/storagetest.cpp')
-rw-r--r--tests/storagetest.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/storagetest.cpp b/tests/storagetest.cpp
index fe80bb7..e872c44 100644
--- a/tests/storagetest.cpp
+++ b/tests/storagetest.cpp
@@ -159,7 +159,12 @@ private Q_SLOTS:
159 bool gotResult = false; 159 bool gotResult = false;
160 bool gotError = false; 160 bool gotError = false;
161 Akonadi2::Storage store(testDataPath, dbName, Akonadi2::Storage::ReadWrite); 161 Akonadi2::Storage store(testDataPath, dbName, Akonadi2::Storage::ReadWrite);
162 int numValues = store.createTransaction(Akonadi2::Storage::ReadOnly).scan("", [&](const QByteArray &key, const QByteArray &value) -> bool { 162 auto transaction = store.createTransaction(Akonadi2::Storage::ReadOnly);
163 auto db = transaction.openDatabase("default", [&](const Akonadi2::Storage::Error &error) {
164 qDebug() << error.message;
165 gotError = true;
166 });
167 int numValues = db.scan("", [&](const QByteArray &key, const QByteArray &value) -> bool {
163 gotResult = true; 168 gotResult = true;
164 return false; 169 return false;
165 }, 170 },