mirror of https://github.com/getdnsapi/getdns.git
Fix failing tests
This commit is contained in:
parent
c2a1e83679
commit
097e6936cb
|
@ -195,7 +195,7 @@ void assert_nxdomain(struct extracted_response *ex_response)
|
||||||
{
|
{
|
||||||
uint32_t rcode;
|
uint32_t rcode;
|
||||||
|
|
||||||
ASSERT_RC(ex_response->status, GETDNS_RESPSTATUS_GOOD, "Unexpected value for \"status\"");
|
ASSERT_RC(ex_response->status, GETDNS_RESPSTATUS_NO_NAME, "Unexpected value for \"status\"");
|
||||||
ASSERT_RC(getdns_dict_get_int(ex_response->header, "rcode", &rcode), GETDNS_RETURN_GOOD, "Failed to extract \"rcode\"");
|
ASSERT_RC(getdns_dict_get_int(ex_response->header, "rcode", &rcode), GETDNS_RETURN_GOOD, "Failed to extract \"rcode\"");
|
||||||
ck_assert_msg(rcode == 3, "Expected rcode == 0, got %d", rcode);
|
ck_assert_msg(rcode == 3, "Expected rcode == 0, got %d", rcode);
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,7 +70,7 @@
|
||||||
GETDNS_RETURN_GOOD, "Return code from getdns_context_set_timeout()");
|
GETDNS_RETURN_GOOD, "Return code from getdns_context_set_timeout()");
|
||||||
|
|
||||||
ASSERT_RC(getdns_context_set_context_update_callback(context, NULL),
|
ASSERT_RC(getdns_context_set_context_update_callback(context, NULL),
|
||||||
GETDNS_RETURN_INVALID_PARAMETER, "Return code from getdns_context_set_context_update_callback()");
|
GETDNS_RETURN_GOOD, "Return code from getdns_context_set_context_update_callback()");
|
||||||
|
|
||||||
CONTEXT_DESTROY;
|
CONTEXT_DESTROY;
|
||||||
|
|
||||||
|
|
|
@ -65,7 +65,7 @@
|
||||||
CONTEXT_CREATE(TRUE);
|
CONTEXT_CREATE(TRUE);
|
||||||
|
|
||||||
ASSERT_RC(getdns_context_set_upstream_recursive_servers(context, NULL),
|
ASSERT_RC(getdns_context_set_upstream_recursive_servers(context, NULL),
|
||||||
GETDNS_RETURN_CONTEXT_UPDATE_FAIL, "Return code from getdns_context_set_upstream_recursive_servers()");
|
GETDNS_RETURN_INVALID_PARAMETER, "Return code from getdns_context_set_upstream_recursive_servers()");
|
||||||
|
|
||||||
|
|
||||||
CONTEXT_DESTROY;
|
CONTEXT_DESTROY;
|
||||||
|
|
|
@ -45,7 +45,7 @@
|
||||||
struct getdns_dict *response = NULL;
|
struct getdns_dict *response = NULL;
|
||||||
|
|
||||||
ASSERT_RC(getdns_service_sync(context, "google.com", NULL, &response),
|
ASSERT_RC(getdns_service_sync(context, "google.com", NULL, &response),
|
||||||
GETDNS_RETURN_BAD_CONTEXT, "Return code from getdns_service_sync()");
|
GETDNS_RETURN_INVALID_PARAMETER, "Return code from getdns_service_sync()");
|
||||||
}
|
}
|
||||||
END_TEST
|
END_TEST
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue