diff options
author | Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk> | 2011-09-29 13:15:30 -0300 |
---|---|---|
committer | Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk> | 2011-09-30 10:49:48 -0300 |
commit | a6f668202f24e28fac36e7c1d607f2b977b49eb1 (patch) | |
tree | 53e20ec24ab40793d4bc47df1dde6c6001e1fe25 | |
parent | cb568e48267d5ef793603e4d0acdabf2b90e172e (diff) |
capabilities test: Add more tests for ConnectionCapabilities::*textChat*.
-rw-r--r-- | qt4/tests/capabilities.cpp | 99 |
1 files changed, 99 insertions, 0 deletions
diff --git a/qt4/tests/capabilities.cpp b/qt4/tests/capabilities.cpp index 169dde1c9..de3cf6ff6 100644 --- a/qt4/tests/capabilities.cpp +++ b/qt4/tests/capabilities.cpp @@ -203,6 +203,105 @@ void TestCapabilities::testConnCapabilities() // conn caps specific QVERIFY(connCaps.conferenceStreamedMediaCalls()); QVERIFY(connCaps.conferenceStreamedMediaCallsWithInvitees()); + + // capabilities base + QVERIFY(!connCaps.textChats()); + QVERIFY(!connCaps.fileTransfers()); + // conn caps specific + QVERIFY(!connCaps.textChatrooms()); + QVERIFY(!connCaps.conferenceTextChats()); + QVERIFY(!connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(!connCaps.conferenceTextChatrooms()); + QVERIFY(!connCaps.conferenceTextChatroomsWithInvitees()); + QVERIFY(!connCaps.contactSearches()); + QVERIFY(!connCaps.contactSearchesWithSpecificServer()); + QVERIFY(!connCaps.contactSearchesWithLimit()); + QVERIFY(!connCaps.contactSearch()); + QVERIFY(!connCaps.contactSearchWithSpecificServer()); + QVERIFY(!connCaps.contactSearchWithLimit()); + QVERIFY(!connCaps.streamTubes()); + + rccSpecs.append(RequestableChannelClassSpec::textChat()); + + connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs); + // capabilities base + QVERIFY(connCaps.textChats()); + // conn caps specific + QVERIFY(!connCaps.textChatrooms()); + QVERIFY(!connCaps.conferenceTextChats()); + QVERIFY(!connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(!connCaps.conferenceTextChatrooms()); + QVERIFY(!connCaps.conferenceTextChatroomsWithInvitees()); + + rccSpecs.append(RequestableChannelClassSpec::textChatroom()); + + connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs); + // capabilities base + QVERIFY(connCaps.textChats()); + // conn caps specific + QVERIFY(connCaps.textChatrooms()); + QVERIFY(!connCaps.conferenceTextChats()); + QVERIFY(!connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(!connCaps.conferenceTextChatrooms()); + QVERIFY(!connCaps.conferenceTextChatroomsWithInvitees()); + + rccSpecs.append(RequestableChannelClassSpec::conferenceTextChat()); + + connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs); + // capabilities base + QVERIFY(connCaps.textChats()); + // conn caps specific + QVERIFY(connCaps.textChatrooms()); + QVERIFY(connCaps.conferenceTextChats()); + QVERIFY(!connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(!connCaps.conferenceTextChatrooms()); + QVERIFY(!connCaps.conferenceTextChatroomsWithInvitees()); + + rccSpecs.append(RequestableChannelClassSpec::conferenceTextChatWithInvitees()); + + connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs); + // capabilities base + QVERIFY(connCaps.textChats()); + // conn caps specific + QVERIFY(connCaps.textChatrooms()); + QVERIFY(connCaps.conferenceTextChats()); + QVERIFY(connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(!connCaps.conferenceTextChatrooms()); + QVERIFY(!connCaps.conferenceTextChatroomsWithInvitees()); + + rccSpecs.append(RequestableChannelClassSpec::conferenceTextChatroom()); + + connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs); + // capabilities base + QVERIFY(connCaps.textChats()); + // conn caps specific + QVERIFY(connCaps.textChatrooms()); + QVERIFY(connCaps.conferenceTextChats()); + QVERIFY(connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(connCaps.conferenceTextChatrooms()); + QVERIFY(!connCaps.conferenceTextChatroomsWithInvitees()); + + rccSpecs.append(RequestableChannelClassSpec::conferenceTextChatroomWithInvitees()); + connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs); + // capabilities base + QVERIFY(connCaps.textChats()); + // conn caps specific + QVERIFY(connCaps.textChatrooms()); + QVERIFY(connCaps.conferenceTextChats()); + QVERIFY(connCaps.conferenceTextChatsWithInvitees()); + QVERIFY(connCaps.conferenceTextChatrooms()); + QVERIFY(connCaps.conferenceTextChatroomsWithInvitees()); + + // capabilities base + QVERIFY(!connCaps.fileTransfers()); + // conn caps specific + QVERIFY(!connCaps.contactSearches()); + QVERIFY(!connCaps.contactSearchesWithSpecificServer()); + QVERIFY(!connCaps.contactSearchesWithLimit()); + QVERIFY(!connCaps.contactSearch()); + QVERIFY(!connCaps.contactSearchWithSpecificServer()); + QVERIFY(!connCaps.contactSearchWithLimit()); + QVERIFY(!connCaps.streamTubes()); } void TestCapabilities::testContactCapabilities() |