Commit fb4b845c authored by Timothée Jaussoin's avatar Timothée Jaussoin :thinking:
Browse files

Move all the FlexiAPI tests timeout to 10s

parent 24680122
Branches
Tags
1 merge request!1844Move all the FlexiAPI tests timeout to 10s
Showing with 19 additions and 19 deletions
...@@ -46,7 +46,7 @@ static void flexiapiPing() { ...@@ -46,7 +46,7 @@ static void flexiapiPing() {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 2000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_STRING_EQUAL(resolvedContent.c_str(), "pong"); BC_ASSERT_STRING_EQUAL(resolvedContent.c_str(), "pong");
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
...@@ -71,7 +71,7 @@ static void flexiapiAccounts() { ...@@ -71,7 +71,7 @@ static void flexiapiAccounts() {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 2000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
// The internal resolver will handle a 401 and then try to re-send // The internal resolver will handle a 401 and then try to re-send
// the request with a proper DIGEST authentication // the request with a proper DIGEST authentication
...@@ -89,7 +89,7 @@ static void flexiapiAccounts() { ...@@ -89,7 +89,7 @@ static void flexiapiAccounts() {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 2000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
BC_ASSERT_STRING_EQUAL(resolvedDomain.c_str(), "sip.example.org"); BC_ASSERT_STRING_EQUAL(resolvedDomain.c_str(), "sip.example.org");
...@@ -112,7 +112,7 @@ static void flexiapiChangeEmail() { ...@@ -112,7 +112,7 @@ static void flexiapiChangeEmail() {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
linphone_core_manager_destroy(marie); linphone_core_manager_destroy(marie);
...@@ -145,7 +145,7 @@ static void flexiapiCreateAccount() { ...@@ -145,7 +145,7 @@ static void flexiapiCreateAccount() {
id = response.json()["id"].asInt(); id = response.json()["id"].asInt();
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 3000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
code = 0; code = 0;
...@@ -163,7 +163,7 @@ static void flexiapiCreateAccount() { ...@@ -163,7 +163,7 @@ static void flexiapiCreateAccount() {
resolvedActivated = response.json()["activated"].asBool(); resolvedActivated = response.json()["activated"].asBool();
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 3000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
BC_ASSERT_TRUE(resolvedActivated); BC_ASSERT_TRUE(resolvedActivated);
BC_ASSERT_STRING_EQUAL(resolvedUsername.c_str(), username.c_str()); BC_ASSERT_STRING_EQUAL(resolvedUsername.c_str(), username.c_str());
...@@ -179,7 +179,7 @@ static void flexiapiCreateAccount() { ...@@ -179,7 +179,7 @@ static void flexiapiCreateAccount() {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 3000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
linphone_core_manager_destroy(marie); linphone_core_manager_destroy(marie);
...@@ -213,7 +213,7 @@ static void flexiapiChangePassword() { ...@@ -213,7 +213,7 @@ static void flexiapiChangePassword() {
fetched = 1; fetched = 1;
}); });
wait_for_until(pauline->lc, NULL, &fetched, 1, 3000); wait_for_until(pauline->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
linphone_address_unref(identityAddress); linphone_address_unref(identityAddress);
......
...@@ -169,7 +169,7 @@ static void flexiapi_remote_provisioning_flow(void) { ...@@ -169,7 +169,7 @@ static void flexiapi_remote_provisioning_flow(void) {
id = response.json()["id"].asInt(); id = response.json()["id"].asInt();
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
// Provision it // Provision it
...@@ -180,7 +180,7 @@ static void flexiapi_remote_provisioning_flow(void) { ...@@ -180,7 +180,7 @@ static void flexiapi_remote_provisioning_flow(void) {
linphone_core_set_provisioning_uri(marie->lc, remoteProvisioningURIWithConfirmationKey.c_str()); linphone_core_set_provisioning_uri(marie->lc, remoteProvisioningURIWithConfirmationKey.c_str());
linphone_core_manager_start(marie, FALSE); linphone_core_manager_start(marie, FALSE);
BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &marie->stat.number_of_LinphoneConfiguringSuccessful, 1, 3000)); BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &marie->stat.number_of_LinphoneConfiguringSuccessful, 1, 10000));
// Re-provision it, without the confirmationKey // Re-provision it, without the confirmationKey
string remoteProvisioningURIAuthenticated = remoteProvisioningURI; string remoteProvisioningURIAuthenticated = remoteProvisioningURI;
...@@ -190,7 +190,7 @@ static void flexiapi_remote_provisioning_flow(void) { ...@@ -190,7 +190,7 @@ static void flexiapi_remote_provisioning_flow(void) {
linphone_core_set_provisioning_uri(marie->lc, remoteProvisioningURIAuthenticated.c_str()); linphone_core_set_provisioning_uri(marie->lc, remoteProvisioningURIAuthenticated.c_str());
linphone_core_manager_start(marie, FALSE); linphone_core_manager_start(marie, FALSE);
BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &marie->stat.number_of_LinphoneConfiguringSuccessful, 1, 3000)); BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &marie->stat.number_of_LinphoneConfiguringSuccessful, 1, 10000));
flexiAPIClient = make_shared<FlexiAPIClient>(marie->lc); flexiAPIClient = make_shared<FlexiAPIClient>(marie->lc);
...@@ -200,7 +200,7 @@ static void flexiapi_remote_provisioning_flow(void) { ...@@ -200,7 +200,7 @@ static void flexiapi_remote_provisioning_flow(void) {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 3000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
linphone_core_manager_destroy(marie); linphone_core_manager_destroy(marie);
...@@ -235,7 +235,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -235,7 +235,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
contactId0 = response.json()["id"].asInt(); contactId0 = response.json()["id"].asInt();
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
fetched = code = 0; fetched = code = 0;
...@@ -247,7 +247,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -247,7 +247,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
contactId1 = response.json()["id"].asInt(); contactId1 = response.json()["id"].asInt();
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
fetched = code = 0; fetched = code = 0;
...@@ -259,7 +259,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -259,7 +259,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
contactId2 = response.json()["id"].asInt(); contactId2 = response.json()["id"].asInt();
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
fetched = code = 0; fetched = code = 0;
...@@ -272,7 +272,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -272,7 +272,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
// Provision it // Provision it
...@@ -297,7 +297,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -297,7 +297,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
linphone_core_set_provisioning_uri(marie->lc, remoteProvisioningURIWithConfirmationKey.c_str()); linphone_core_set_provisioning_uri(marie->lc, remoteProvisioningURIWithConfirmationKey.c_str());
linphone_core_manager_start(marie, FALSE); linphone_core_manager_start(marie, FALSE);
BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &marie->stat.number_of_LinphoneConfiguringSuccessful, 1, 3000)); BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &marie->stat.number_of_LinphoneConfiguringSuccessful, 1, 10000));
// Check if the friend list has been parsed // Check if the friend list has been parsed
BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &stats->new_list_count, 1, 5000)); BC_ASSERT_TRUE(wait_for_until(marie->lc, NULL, &stats->new_list_count, 1, 5000));
...@@ -340,7 +340,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -340,7 +340,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 15000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
LinphoneFriendList *friendList2 = linphone_core_create_friend_list(marie->lc); LinphoneFriendList *friendList2 = linphone_core_create_friend_list(marie->lc);
linphone_friend_list_set_type(friendList2, LinphoneFriendListTypeVCard4); linphone_friend_list_set_type(friendList2, LinphoneFriendListTypeVCard4);
...@@ -375,7 +375,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) { ...@@ -375,7 +375,7 @@ static void flexiapi_remote_provisioning_contacts_list_flow(void) {
fetched = 1; fetched = 1;
}); });
wait_for_until(marie->lc, NULL, &fetched, 1, 3000); wait_for_until(marie->lc, NULL, &fetched, 1, 10000);
BC_ASSERT_EQUAL(code, 200, int, "%d"); BC_ASSERT_EQUAL(code, 200, int, "%d");
linphone_core_cbs_unref(cbs); linphone_core_cbs_unref(cbs);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment