mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Assert rs are added in con and con_md tests
This commit is contained in:
committed by
Nick Mathewson
parent
185c93c954
commit
6a5528356f
@@ -1920,12 +1920,20 @@ test_a_networkstatus(
|
||||
|
||||
/* Check the routerstatuses. */
|
||||
n_rs = smartlist_len(con->routerstatus_list);
|
||||
tt_assert(n_rs);
|
||||
for (idx = 0; idx < n_rs; ++idx) {
|
||||
rs = smartlist_get(con->routerstatus_list, idx);
|
||||
tt_assert(rs);
|
||||
rs_test(rs, now);
|
||||
}
|
||||
|
||||
n_rs = smartlist_len(con_md->routerstatus_list);
|
||||
tt_assert(n_rs);
|
||||
for (idx = 0; idx < n_rs; ++idx) {
|
||||
rs = smartlist_get(con_md->routerstatus_list, idx);
|
||||
tt_assert(rs);
|
||||
}
|
||||
|
||||
/* Check signatures. the first voter is a pseudo-entry with a legacy key.
|
||||
* The second one hasn't signed. The fourth one has signed: validate it. */
|
||||
voter = smartlist_get(con->voters, 1);
|
||||
|
||||
Reference in New Issue
Block a user