diff options
Diffstat (limited to 'src/test/test_hs_cache.c')
-rw-r--r-- | src/test/test_hs_cache.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/src/test/test_hs_cache.c b/src/test/test_hs_cache.c index f25bba3584..df96b2c791 100644 --- a/src/test/test_hs_cache.c +++ b/src/test/test_hs_cache.c @@ -462,9 +462,10 @@ test_hsdir_revision_counter_check(void *arg) static networkstatus_t mock_ns; static networkstatus_t * -mock_networkstatus_get_live_consensus(time_t now) +mock_networkstatus_get_reasonably_live_consensus(time_t now, int flavor) { (void) now; + (void) flavor; return &mock_ns; } @@ -485,8 +486,8 @@ test_client_cache(void *arg) /* Initialize HSDir cache subsystem */ init_test(); - MOCK(networkstatus_get_live_consensus, - mock_networkstatus_get_live_consensus); + MOCK(networkstatus_get_reasonably_live_consensus, + mock_networkstatus_get_reasonably_live_consensus); /* Set consensus time */ parse_rfc1123_time("Sat, 26 Oct 1985 13:00:00 UTC", @@ -589,8 +590,8 @@ test_client_cache_decrypt(void *arg) /* Initialize HSDir cache subsystem */ hs_init(); - MOCK(networkstatus_get_live_consensus, - mock_networkstatus_get_live_consensus); + MOCK(networkstatus_get_reasonably_live_consensus, + mock_networkstatus_get_reasonably_live_consensus); /* Set consensus time */ parse_rfc1123_time("Sat, 26 Oct 1985 13:00:00 UTC", @@ -645,7 +646,7 @@ test_client_cache_decrypt(void *arg) hs_free_all(); - UNMOCK(networkstatus_get_live_consensus); + UNMOCK(networkstatus_get_reasonably_live_consensus); } static void @@ -659,8 +660,8 @@ test_client_cache_remove(void *arg) hs_init(); - MOCK(networkstatus_get_live_consensus, - mock_networkstatus_get_live_consensus); + MOCK(networkstatus_get_reasonably_live_consensus, + mock_networkstatus_get_reasonably_live_consensus); /* Set consensus time. Lookup will not return the entry if it has expired * and it is checked against the consensus valid_after time. */ @@ -698,7 +699,7 @@ test_client_cache_remove(void *arg) hs_descriptor_free(desc1); hs_free_all(); - UNMOCK(networkstatus_get_live_consensus); + UNMOCK(networkstatus_get_reasonably_live_consensus); } struct testcase_t hs_cache[] = { |