From 9bdde8902716bf923a78d8c287acadb0c4d2ffcd Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Wed, 7 Sep 2011 17:48:21 -0400 Subject: Make the unit tests pass again after the bug2003 fix --- src/test/test_dir.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/test') diff --git a/src/test/test_dir.c b/src/test/test_dir.c index 8fd94289a9..8a0fe9a677 100644 --- a/src/test/test_dir.c +++ b/src/test/test_dir.c @@ -7,10 +7,12 @@ #define DIRSERV_PRIVATE #define DIRVOTE_PRIVATE #define ROUTER_PRIVATE +#define HIBERNATE_PRIVATE #include "or.h" #include "directory.h" #include "dirserv.h" #include "dirvote.h" +#include "hibernate.h" #include "networkstatus.h" #include "router.h" #include "routerlist.h" @@ -85,6 +87,8 @@ test_dir_formats(void) test_assert(pk1 && pk2 && pk3); + hibernate_set_state_for_testing_(HIBERNATE_STATE_LIVE); + get_platform_str(platform, sizeof(platform)); r1 = tor_malloc_zero(sizeof(routerinfo_t)); r1->address = tor_strdup("18.244.0.1"); @@ -1301,7 +1305,7 @@ test_dir_v3_networkstatus(void) } #define DIR_LEGACY(name) \ - { #name, legacy_test_helper, 0, &legacy_setup, test_dir_ ## name } + { #name, legacy_test_helper, TT_FORK, &legacy_setup, test_dir_ ## name } #define DIR(name) \ { #name, test_dir_##name, 0, NULL, NULL } -- cgit v1.2.3-54-g00ecf