diff options
author | Nick Mathewson <nickm@torproject.org> | 2004-10-16 21:57:24 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2004-10-16 21:57:24 +0000 |
commit | 25a046df7422560b16dfdb302df9621309d5fa77 (patch) | |
tree | 78ddfa79db9b0254f3479d9c0c5529788c8062a2 /src/or/test.c | |
parent | 47dc024f7eb268dca65949d68914aa29b2840711 (diff) | |
download | tor-25a046df7422560b16dfdb302df9621309d5fa77.tar tor-25a046df7422560b16dfdb302df9621309d5fa77.tar.gz |
Fix unit tests, make it compile
svn:r2543
Diffstat (limited to 'src/or/test.c')
-rw-r--r-- | src/or/test.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/or/test.c b/src/or/test.c index a7b1e51ea..f317d674c 100644 --- a/src/or/test.c +++ b/src/or/test.c @@ -661,12 +661,12 @@ test_util() { cp = NULL; u32 = 3; u16 = 3; test_assert(!parse_addr_port("1.2.3.4", &cp, &u32, &u16)); test_streq(cp, "1.2.3.4"); - test_eq(u32, htonl(0x01020304u)); + test_eq(u32, 0x01020304u); test_eq(u16, 0); tor_free(cp); test_assert(!parse_addr_port("4.3.2.1:99", &cp, &u32, &u16)); test_streq(cp, "4.3.2.1"); - test_eq(u32, htonl(0x04030201u)); + test_eq(u32, 0x04030201u); test_eq(u16, 99); tor_free(cp); test_assert(!parse_addr_port("nonexistent.address:4040", &cp, NULL, &u16)); @@ -675,13 +675,13 @@ test_util() { tor_free(cp); test_assert(!parse_addr_port("localhost:9999", &cp, &u32, &u16)); test_streq(cp, "localhost"); - test_eq(u32, htonl(0x7f000001u)); + test_eq(u32, 0x7f000001u); test_eq(u16, 9999); tor_free(cp); u32 = 3; test_assert(!parse_addr_port("localhost", NULL, &u32, &u16)); test_eq(cp, NULL); - test_eq(u32, htonl(0x7f000001u)); + test_eq(u32, 0x7f000001u); test_eq(u16, 0); tor_free(cp); |