mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-11 05:33:47 +01:00
Another round of unittest massaging for tor!212.
This commit is contained in:
parent
16915ec515
commit
177b535e72
@ -800,6 +800,8 @@ test_hs_control_add_onion_helper_add_service(void *arg)
|
|||||||
rend_service_port_config_t *portcfg;
|
rend_service_port_config_t *portcfg;
|
||||||
smartlist_t *portcfgs;
|
smartlist_t *portcfgs;
|
||||||
char *address_out_good, *address_out_bad;
|
char *address_out_good, *address_out_bad;
|
||||||
|
hs_service_t *service_good = NULL;
|
||||||
|
hs_service_t *service_bad = NULL;
|
||||||
|
|
||||||
(void) arg;
|
(void) arg;
|
||||||
|
|
||||||
@ -831,7 +833,7 @@ test_hs_control_add_onion_helper_add_service(void *arg)
|
|||||||
add_onion_helper_add_service(HS_VERSION_THREE, &sk_good, portcfgs, 1, 1,
|
add_onion_helper_add_service(HS_VERSION_THREE, &sk_good, portcfgs, 1, 1,
|
||||||
REND_V3_AUTH, NULL, list_good, &address_out_good);
|
REND_V3_AUTH, NULL, list_good, &address_out_good);
|
||||||
|
|
||||||
hs_service_t *service_good = find_service(global_map, &pk_good);
|
service_good = find_service(global_map, &pk_good);
|
||||||
tt_int_op(smartlist_len(service_good->config.clients), OP_EQ, 1);
|
tt_int_op(smartlist_len(service_good->config.clients), OP_EQ, 1);
|
||||||
|
|
||||||
hs_service_free(service_good);
|
hs_service_free(service_good);
|
||||||
@ -846,7 +848,7 @@ test_hs_control_add_onion_helper_add_service(void *arg)
|
|||||||
add_onion_helper_add_service(HS_VERSION_THREE, &sk_bad, portcfgs, 1, 1,
|
add_onion_helper_add_service(HS_VERSION_THREE, &sk_bad, portcfgs, 1, 1,
|
||||||
REND_V3_AUTH, NULL, list_bad, &address_out_bad);
|
REND_V3_AUTH, NULL, list_bad, &address_out_bad);
|
||||||
|
|
||||||
hs_service_t *service_bad = find_service(global_map, &pk_bad);
|
service_bad = find_service(global_map, &pk_bad);
|
||||||
|
|
||||||
tt_int_op(smartlist_len(service_bad->config.clients), OP_EQ, 0);
|
tt_int_op(smartlist_len(service_bad->config.clients), OP_EQ, 0);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user