mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
TestsUI: fix notification test
This commit is contained in:
parent
de39870257
commit
5dd483dcb5
5 changed files with 13 additions and 7 deletions
|
|
@ -2075,9 +2075,12 @@ static int comp_call_state_paused(const LinphoneCall *call, const void *param) {
|
|||
@"call-snd=%@;pn-msg-snd=msg.caf",
|
||||
[[NSBundle mainBundle] bundleIdentifier], APPMODE_SUFFIX, tokenString, ring];
|
||||
|
||||
LOGI(@"Proxy config %s configured for push notifications with contact: %@",
|
||||
linphone_proxy_config_get_identity(proxyCfg), params);
|
||||
linphone_proxy_config_set_contact_uri_parameters(proxyCfg, [params UTF8String]);
|
||||
linphone_proxy_config_set_contact_parameters(proxyCfg, NULL);
|
||||
} else {
|
||||
LOGI(@"Proxy config %s NOT configured for push notifications", linphone_proxy_config_get_identity(proxyCfg));
|
||||
// no push token:
|
||||
linphone_proxy_config_set_contact_uri_parameters(proxyCfg, NULL);
|
||||
linphone_proxy_config_set_contact_parameters(proxyCfg, NULL);
|
||||
|
|
|
|||
|
|
@ -71,6 +71,10 @@
|
|||
return @"test.linphone.org";
|
||||
}
|
||||
|
||||
- (NSString *)accountProxyRoute {
|
||||
return [[self accountDomain] stringByAppendingString:@";transport=tcp"];
|
||||
}
|
||||
|
||||
- (NSString *)getUUID {
|
||||
return [[[NSUUID UUID] UUIDString] substringToIndex:8].lowercaseString;
|
||||
}
|
||||
|
|
@ -122,10 +126,9 @@
|
|||
|
||||
LinphoneProxyConfig *testProxy = linphone_proxy_config_new();
|
||||
linphone_proxy_config_set_identity_address(testProxy, testAddr);
|
||||
char *server_addr = ms_strdup_printf("%s;transport=tcp", linphone_address_get_domain(testAddr));
|
||||
linphone_proxy_config_set_server_addr(testProxy, server_addr);
|
||||
linphone_proxy_config_set_route(testProxy, server_addr);
|
||||
ms_free(server_addr);
|
||||
linphone_proxy_config_set_server_addr(testProxy, [self accountProxyRoute].UTF8String);
|
||||
linphone_proxy_config_set_route(testProxy, [self accountProxyRoute].UTF8String);
|
||||
linphone_proxy_config_set_ref_key(testProxy, "push_notification");
|
||||
|
||||
LinphoneAuthInfo *testAuth = linphone_auth_info_new(linphone_address_get_username(testAddr), NULL,
|
||||
linphone_address_get_username(testAddr), NULL, NULL,
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
[tester tapViewWithAccessibilityLabel:@"Chat"];
|
||||
|
||||
// it can take several seconds to receive the remote push notification...
|
||||
int timeout = 5;
|
||||
int timeout = 15;
|
||||
while (timeout > 0) {
|
||||
[tester tryFindingViewWithAccessibilityLabel:@"Contact name, Message" error:nil];
|
||||
timeout--;
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit e654c008283c942345ac20540981ba854d9138ba
|
||||
Subproject commit 9e9857e103d22a4995970133bc2866befadcd198
|
||||
|
|
@ -1 +1 @@
|
|||
Subproject commit 36fd57c45b9b6ebbafbe57e5be4c5e2120a281cf
|
||||
Subproject commit 9eb98a78f9f44a5506d7ca627aaf5e6bbec3f0db
|
||||
Loading…
Add table
Reference in a new issue