[Telepathy-commits] [telepathy-qt4/master] Verify that the closure accessors work in TestContacts::testForHandles

Olli Salli olli.salli at collabora.co.uk
Thu Jan 29 12:42:39 PST 2009


---
 tests/dbus/contacts.cpp |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/tests/dbus/contacts.cpp b/tests/dbus/contacts.cpp
index bcb9cf7..32fbd38 100644
--- a/tests/dbus/contacts.cpp
+++ b/tests/dbus/contacts.cpp
@@ -189,6 +189,17 @@ void TestContacts::testForHandles()
 
     // Get contacts for the mixture of valid and invalid handles
     PendingContacts *pending = mConn->contactManager()->contactsForHandles(handles);
+
+    // Test the closure accessors
+    QCOMPARE(pending->contactManager(), mConn->contactManager());
+    QCOMPARE(pending->features(), QSet<Contact::Feature>());
+
+    QVERIFY(pending->isForHandles());
+    QVERIFY(!pending->isForIdentifiers());
+
+    QCOMPARE(pending->handles(), handles);
+
+    // Wait for the contacts to be built
     QVERIFY(connect(pending,
                 SIGNAL(finished(Telepathy::Client::PendingOperation*)),
                 SLOT(expectPendingContactsFinished(Telepathy::Client::PendingOperation*))));
-- 
1.5.6.5




More information about the telepathy-commits mailing list