summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorGeorge Kadianakis <desnacked@riseup.net>2017-10-03 14:38:53 +0300
committerGeorge Kadianakis <desnacked@riseup.net>2017-10-03 14:41:20 +0300
commit5352785d0caec23f753ae7fcab4449b03f5643b8 (patch)
treeabb5e756a3a1b77af2869b1faff18570216b6426 /src/test
parentf2231306ba58cc5d9a5addb41eb7f287e3802746 (diff)
downloadtor-5352785d0caec23f753ae7fcab4449b03f5643b8.tar.gz
tor-5352785d0caec23f753ae7fcab4449b03f5643b8.zip
entrynodes: Error msg for missing guard descs is now more informative.
Diffstat (limited to 'src/test')
-rw-r--r--src/test/test_entrynodes.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/test/test_entrynodes.c b/src/test/test_entrynodes.c
index 36e457bdf1..472383f382 100644
--- a/src/test/test_entrynodes.c
+++ b/src/test/test_entrynodes.c
@@ -1641,9 +1641,9 @@ test_entry_guard_manage_primary(void *arg)
/* Do some dirinfo checks */
{
- /* Check that we have all required dirinfo for the primaries (that's done in
- * big_fake_network_setup()) */
- char *dir_info_str = guard_selection_get_dir_info_status_str(gs);
+ /* Check that we have all required dirinfo for the primaries (that's done
+ * in big_fake_network_setup()) */
+ char *dir_info_str = guard_selection_get_dir_info_status_str(gs, 0, 0, 0);
tt_assert(!dir_info_str);
/* Now artificially remove the first primary's descriptor and re-check */
@@ -1652,9 +1652,10 @@ test_entry_guard_manage_primary(void *arg)
/* Change the first primary's identity digest so that the mocked functions
* can't find its descriptor */
memset(first_primary->identity, 9, sizeof(first_primary->identity));
- dir_info_str = guard_selection_get_dir_info_status_str(gs);
+ dir_info_str = guard_selection_get_dir_info_status_str(gs, 1, 2, 3);
tt_str_op(dir_info_str, OP_EQ,
- "We're missing descriptors for 1/2 of our primary entry guards");
+ "We're missing descriptors for 1/2 of our primary entry guards "
+ "(total microdescriptors: 2/3).");
tor_free(dir_info_str);
}