From 5bb617236704be189e68c713d95dac002912a219 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Thu, 8 May 2014 13:08:13 -0400 Subject: Fix numerous type errors in the unit tests Remove tinytest casts that were suppressing them. Fix for #11825. --- src/test/test_buffers.c | 2 +- src/test/test_circuitlist.c | 2 +- src/test/test_extorport.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/test') diff --git a/src/test/test_buffers.c b/src/test/test_buffers.c index cb78a4bb5..78b3aead6 100644 --- a/src/test/test_buffers.c +++ b/src/test/test_buffers.c @@ -222,7 +222,7 @@ test_buffer_pullup(void *arg) buf_pullup(buf, 16, 1); buf_get_first_chunk_data(buf, &cp, &sz); tt_ptr_op(cp, ==, NULL); - tt_ptr_op(sz, ==, 0); + tt_uint_op(sz, ==, 0); /* Let's make sure nothing got allocated */ tt_int_op(buf_get_total_allocation(), ==, 0); diff --git a/src/test/test_circuitlist.c b/src/test/test_circuitlist.c index 7b7d4153e..b19edd1fd 100644 --- a/src/test/test_circuitlist.c +++ b/src/test/test_circuitlist.c @@ -53,7 +53,7 @@ circuitmux_detach_mock(circuitmux_t *cmux, circuit_t *circ) tt_int_op(cam.ncalls, ==, 1); \ tt_ptr_op(cam.cmux, ==, (mux_)); \ tt_ptr_op(cam.circ, ==, (circ_)); \ - tt_ptr_op(cam.dir, ==, (dir_)); \ + tt_int_op(cam.dir, ==, (dir_)); \ memset(&cam, 0, sizeof(cam)); \ } while (0) diff --git a/src/test/test_extorport.c b/src/test/test_extorport.c index d47792fdb..64ed24eee 100644 --- a/src/test/test_extorport.c +++ b/src/test/test_extorport.c @@ -338,7 +338,7 @@ test_ext_or_cookie_auth_testvec(void *arg) handle_client_auth_nonce(client_nonce, 32, &client_hash, &reply, &reply_len)); tt_ptr_op(reply, !=, NULL ); - tt_ptr_op(reply_len, ==, 64); + tt_uint_op(reply_len, ==, 64); test_memeq(reply+32, "te road There is always another ", 32); /* HMACSHA256("Gliding wrapt in a brown mantle," * "ExtORPort authentication server-to-client hash" -- cgit v1.2.3