summaryrefslogtreecommitdiff
path: root/qt4/tests
diff options
context:
space:
mode:
authorAndre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>2011-09-29 13:03:50 -0300
committerAndre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>2011-09-30 10:49:48 -0300
commitcb568e48267d5ef793603e4d0acdabf2b90e172e (patch)
tree8df71d8834613fde6f01d85139f008cb825aefd4 /qt4/tests
parentccda3cffd7f5a1df7b906a9e07ba5fde1c4d619c (diff)
capabilities test: Add more tests for ConnectionCapabilities::*streamedMedia*.
Diffstat (limited to 'qt4/tests')
-rw-r--r--qt4/tests/capabilities.cpp74
1 files changed, 74 insertions, 0 deletions
diff --git a/qt4/tests/capabilities.cpp b/qt4/tests/capabilities.cpp
index cb5beca7a..169dde1c9 100644
--- a/qt4/tests/capabilities.cpp
+++ b/qt4/tests/capabilities.cpp
@@ -129,6 +129,80 @@ void TestCapabilities::testConnCapabilities()
QVERIFY(connCaps.contactSearchWithSpecificServer());
QVERIFY(connCaps.contactSearchWithLimit());
QCOMPARE(connCaps.allClassSpecs(), rccSpecs);
+
+ // start over
+ rccSpecs.clear();
+ rccSpecs.append(RequestableChannelClassSpec::streamedMediaCall());
+
+ connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs);
+ // capabilities base
+ QVERIFY(connCaps.streamedMediaCalls());
+ QVERIFY(!connCaps.streamedMediaAudioCalls());
+ QVERIFY(!connCaps.streamedMediaVideoCalls());
+ QVERIFY(!connCaps.streamedMediaVideoCallsWithAudio());
+ // conn caps specific
+ QVERIFY(!connCaps.conferenceStreamedMediaCalls());
+ QVERIFY(!connCaps.conferenceStreamedMediaCallsWithInvitees());
+
+ rccSpecs.append(RequestableChannelClassSpec::streamedMediaAudioCall());
+
+ connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs);
+ // capabilities base
+ QVERIFY(connCaps.streamedMediaCalls());
+ QVERIFY(connCaps.streamedMediaAudioCalls());
+ QVERIFY(!connCaps.streamedMediaVideoCalls());
+ QVERIFY(!connCaps.streamedMediaVideoCallsWithAudio());
+ // conn caps specific
+ QVERIFY(!connCaps.conferenceStreamedMediaCalls());
+ QVERIFY(!connCaps.conferenceStreamedMediaCallsWithInvitees());
+
+ rccSpecs.append(RequestableChannelClassSpec::streamedMediaVideoCall());
+
+ connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs);
+ // capabilities base
+ QVERIFY(connCaps.streamedMediaCalls());
+ QVERIFY(connCaps.streamedMediaAudioCalls());
+ QVERIFY(connCaps.streamedMediaVideoCalls());
+ QVERIFY(!connCaps.streamedMediaVideoCallsWithAudio());
+ // conn caps specific
+ QVERIFY(!connCaps.conferenceStreamedMediaCalls());
+ QVERIFY(!connCaps.conferenceStreamedMediaCallsWithInvitees());
+
+ rccSpecs.append(RequestableChannelClassSpec::streamedMediaVideoCallWithAudio());
+
+ connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs);
+ // capabilities base
+ QVERIFY(connCaps.streamedMediaCalls());
+ QVERIFY(connCaps.streamedMediaAudioCalls());
+ QVERIFY(connCaps.streamedMediaVideoCalls());
+ QVERIFY(connCaps.streamedMediaVideoCallsWithAudio());
+ // conn caps specific
+ QVERIFY(!connCaps.conferenceStreamedMediaCalls());
+ QVERIFY(!connCaps.conferenceStreamedMediaCallsWithInvitees());
+
+ rccSpecs.append(RequestableChannelClassSpec::conferenceStreamedMediaCall());
+
+ connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs);
+ // capabilities base
+ QVERIFY(connCaps.streamedMediaCalls());
+ QVERIFY(connCaps.streamedMediaAudioCalls());
+ QVERIFY(connCaps.streamedMediaVideoCalls());
+ QVERIFY(connCaps.streamedMediaVideoCallsWithAudio());
+ // conn caps specific
+ QVERIFY(connCaps.conferenceStreamedMediaCalls());
+ QVERIFY(!connCaps.conferenceStreamedMediaCallsWithInvitees());
+
+ rccSpecs.append(RequestableChannelClassSpec::conferenceStreamedMediaCallWithInvitees());
+
+ connCaps = TestBackdoors::createConnectionCapabilities(rccSpecs);
+ // capabilities base
+ QVERIFY(connCaps.streamedMediaCalls());
+ QVERIFY(connCaps.streamedMediaAudioCalls());
+ QVERIFY(connCaps.streamedMediaVideoCalls());
+ QVERIFY(connCaps.streamedMediaVideoCallsWithAudio());
+ // conn caps specific
+ QVERIFY(connCaps.conferenceStreamedMediaCalls());
+ QVERIFY(connCaps.conferenceStreamedMediaCallsWithInvitees());
}
void TestCapabilities::testContactCapabilities()