Skip to content
Snippets Groups Projects
Commit 87c5f3ce authored by Sébastien Blin's avatar Sébastien Blin Committed by Adrien Béraud
Browse files

misc: fix ut_conversation_call

Change-Id: I6dc0b22f4336dde4db1d6a869e4447ad51d809ff
parent 5b56cc7e
No related branches found
No related tags found
No related merge requests found
...@@ -821,8 +821,9 @@ ConversationCallTest::testJoinWhileActiveCall() ...@@ -821,8 +821,9 @@ ConversationCallTest::testJoinWhileActiveCall()
&& data.messages.rbegin()->at("type") == "application/call-history+json"; && data.messages.rbegin()->at("type") == "application/call-history+json";
}; };
// should get message // should get message
cv.wait_for(lk, 30s, [&]() { return lastCommitIsCall(aliceData_); }); CPPUNIT_ASSERT(cv.wait_for(lk, 30s, [&]() { return lastCommitIsCall(aliceData_); }));
auto confId = aliceData_.messages.rbegin()->at("confId");
libjami::addConversationMember(aliceId, aliceData_.id, bobUri); libjami::addConversationMember(aliceId, aliceData_.id, bobUri);
CPPUNIT_ASSERT(cv.wait_for(lk, 60s, [&]() { return bobData_.requestReceived; })); CPPUNIT_ASSERT(cv.wait_for(lk, 60s, [&]() { return bobData_.requestReceived; }));
...@@ -834,13 +835,12 @@ ConversationCallTest::testJoinWhileActiveCall() ...@@ -834,13 +835,12 @@ ConversationCallTest::testJoinWhileActiveCall()
CPPUNIT_ASSERT(libjami::getActiveCalls(bobId, bobData_.id).size() == 1); CPPUNIT_ASSERT(libjami::getActiveCalls(bobId, bobData_.id).size() == 1);
// hangup bob MUST NOT stop the conference
aliceData_.messages.clear(); aliceData_.messages.clear();
bobData_.messages.clear(); bobData_.messages.clear();
aliceData_.conferenceChanged = false; aliceData_.conferenceChanged = false;
Manager::instance().hangupCall(aliceId, callId); Manager::instance().hangupConference(aliceId, confId);
CPPUNIT_ASSERT(!cv.wait_for(lk, 10s, [&]() { return aliceData_.conferenceRemoved; })); CPPUNIT_ASSERT(cv.wait_for(lk, 10s, [&]() { return aliceData_.conferenceRemoved; }));
} }
void void
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment