mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-28 00:29:21 +00:00
add more test for invite without sdp
This commit is contained in:
parent
1ffb06aecc
commit
7eefcf399f
1 changed files with 35 additions and 8 deletions
|
|
@ -587,10 +587,7 @@ static bool_t check_ice(LinphoneCoreManager* caller, LinphoneCoreManager* callee
|
|||
return success;
|
||||
}
|
||||
|
||||
static void _call_with_ice(bool_t caller_with_ice, bool_t callee_with_ice, bool_t random_ports) {
|
||||
LinphoneCoreManager* marie = linphone_core_manager_new( "marie_rc");
|
||||
LinphoneCoreManager* pauline = linphone_core_manager_new( "pauline_rc");
|
||||
|
||||
static void _call_with_ice_base(LinphoneCoreManager* pauline,LinphoneCoreManager* marie, bool_t caller_with_ice, bool_t callee_with_ice, bool_t random_ports) {
|
||||
if (callee_with_ice){
|
||||
linphone_core_set_firewall_policy(marie->lc,LinphonePolicyUseIce);
|
||||
linphone_core_set_stun_server(marie->lc,"stun.linphone.org");
|
||||
|
|
@ -624,14 +621,31 @@ static void _call_with_ice(bool_t caller_with_ice, bool_t callee_with_ice, bool_
|
|||
CU_ASSERT_TRUE(wait_for(pauline->lc,marie->lc,&pauline->stat.number_of_LinphoneCallEnd,1));
|
||||
CU_ASSERT_TRUE(wait_for(pauline->lc,marie->lc,&marie->stat.number_of_LinphoneCallEnd,1));
|
||||
|
||||
}
|
||||
static void _call_with_ice(bool_t caller_with_ice, bool_t callee_with_ice, bool_t random_ports) {
|
||||
LinphoneCoreManager* marie = linphone_core_manager_new( "marie_rc");
|
||||
LinphoneCoreManager* pauline = linphone_core_manager_new( "pauline_rc");
|
||||
_call_with_ice_base(pauline,marie,caller_with_ice,callee_with_ice,random_ports);
|
||||
linphone_core_manager_destroy(marie);
|
||||
linphone_core_manager_destroy(pauline);
|
||||
}
|
||||
|
||||
static void call_with_ice(void){
|
||||
_call_with_ice(TRUE,TRUE,FALSE);
|
||||
}
|
||||
|
||||
static void call_with_ice_no_sdp(void){
|
||||
#ifdef 0
|
||||
LinphoneCoreManager* marie = linphone_core_manager_new( "marie_rc");
|
||||
LinphoneCoreManager* pauline = linphone_core_manager_new( "pauline_rc");
|
||||
|
||||
linphone_core_enable_sdp_200_ack(pauline->lc,TRUE);
|
||||
_call_with_ice_base(pauline,marie,TRUE,TRUE,FALSE);
|
||||
|
||||
linphone_core_manager_destroy(marie);
|
||||
linphone_core_manager_destroy(pauline);
|
||||
#endif
|
||||
}
|
||||
|
||||
static void call_with_ice_random_ports(void){
|
||||
_call_with_ice(TRUE,TRUE,TRUE);
|
||||
}
|
||||
|
|
@ -909,9 +923,7 @@ static void call_with_declined_video(void) {
|
|||
linphone_core_manager_destroy(pauline);
|
||||
}
|
||||
|
||||
static void video_call(void) {
|
||||
LinphoneCoreManager* marie = linphone_core_manager_new( "marie_rc");
|
||||
LinphoneCoreManager* pauline = linphone_core_manager_new( "pauline_rc");
|
||||
static void video_call_base(LinphoneCoreManager* pauline,LinphoneCoreManager* marie) {
|
||||
LinphoneCallParams* callee_params;
|
||||
LinphoneCallParams* caller_params;
|
||||
LinphoneCall* marie_call;
|
||||
|
|
@ -946,6 +958,19 @@ static void video_call(void) {
|
|||
CU_ASSERT_TRUE(wait_for(pauline->lc,marie->lc,&marie->stat.number_of_LinphoneCallEnd,1));
|
||||
}
|
||||
|
||||
}
|
||||
static void video_call(void) {
|
||||
LinphoneCoreManager* marie = linphone_core_manager_new( "marie_rc");
|
||||
LinphoneCoreManager* pauline = linphone_core_manager_new( "pauline_rc");
|
||||
video_call_base(marie,pauline);
|
||||
linphone_core_manager_destroy(marie);
|
||||
linphone_core_manager_destroy(pauline);
|
||||
}
|
||||
static void video_call_no_sdp(void) {
|
||||
LinphoneCoreManager* marie = linphone_core_manager_new( "marie_rc");
|
||||
LinphoneCoreManager* pauline = linphone_core_manager_new( "pauline_rc");
|
||||
linphone_core_enable_sdp_200_ack(pauline->lc,TRUE);
|
||||
video_call_base(pauline,marie);
|
||||
linphone_core_manager_destroy(marie);
|
||||
linphone_core_manager_destroy(pauline);
|
||||
}
|
||||
|
|
@ -2122,6 +2147,7 @@ test_t call_tests[] = {
|
|||
{ "SRTP call with declined srtp", call_with_declined_srtp },
|
||||
#ifdef VIDEO_ENABLED
|
||||
{ "Simple video call",video_call},
|
||||
{ "Video call without SDP",video_call_no_sdp},
|
||||
{ "SRTP ice video call", srtp_video_ice_call },
|
||||
{ "ZRTP ice video call", zrtp_video_ice_call },
|
||||
{ "Call with video added", call_with_video_added },
|
||||
|
|
@ -2144,6 +2170,7 @@ test_t call_tests[] = {
|
|||
{ "Unattended call transfer with error", unattended_call_transfer_with_error },
|
||||
{ "Call transfer existing call outgoing call", call_transfer_existing_call_outgoing_call },
|
||||
{ "Call with ICE", call_with_ice },
|
||||
{ "Call with ICE without SDP", call_with_ice_no_sdp },
|
||||
{ "Call with ICE (random ports)", call_with_ice_random_ports },
|
||||
{ "Call from ICE to not ICE",ice_to_not_ice},
|
||||
{ "Call from not ICE to ICE",not_ice_to_ice},
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue