aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_hs_service.c
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2017-09-07 08:58:55 -0400
committerGeorge Kadianakis <desnacked@riseup.net>2017-09-08 19:07:00 +0300
commitf2c93f9943543946ceaa8eece63eeecea3ffd4f2 (patch)
tree0e540a96f98bf1237dd06c165fb84153090d5d45 /src/test/test_hs_service.c
parent87585ebd2d8a902e729733f1f1cb6a23373a8c33 (diff)
downloadtor-f2c93f9943543946ceaa8eece63eeecea3ffd4f2.tar.gz
tor-f2c93f9943543946ceaa8eece63eeecea3ffd4f2.zip
test: Fix use out of scope and consensus timings
First, this fixes #23372. Second, the consensus timings for the build descriptor have been changed to the current test can pass. More extensive tests of descriptor rotation are coming in a commit near you because the rotation and time period logic has been changed. Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/test/test_hs_service.c')
-rw-r--r--src/test/test_hs_service.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/test_hs_service.c b/src/test/test_hs_service.c
index 874056567c..6592055b97 100644
--- a/src/test/test_hs_service.c
+++ b/src/test/test_hs_service.c
@@ -1022,6 +1022,7 @@ test_build_update_descriptors(void *arg)
node_t *node;
hs_service_t *service;
hs_service_intro_point_t *ip_cur, *ip_next;
+ routerinfo_t ri;
(void) arg;
@@ -1033,9 +1034,9 @@ test_build_update_descriptors(void *arg)
dummy_state = tor_malloc_zero(sizeof(or_state_t));
- ret = parse_rfc1123_time("Sat, 26 Oct 1985 13:00:00 UTC",
+ ret = parse_rfc1123_time("Sat, 26 Oct 1985 03:00:00 UTC",
&mock_ns.valid_after);
- ret = parse_rfc1123_time("Sat, 26 Oct 1985 14:00:00 UTC",
+ ret = parse_rfc1123_time("Sat, 26 Oct 1985 04:00:00 UTC",
&mock_ns.fresh_until);
tt_int_op(ret, OP_EQ, 0);
@@ -1085,7 +1086,6 @@ test_build_update_descriptors(void *arg)
/* Now, we'll setup a node_t. */
{
- routerinfo_t ri;
tor_addr_t ipv4_addr;
curve25519_secret_key_t curve25519_secret_key;