Fix unit tests with -DUSE_DEBUG enabled

If you were to enable USE_DEBUG and slog through all 700+ MB of
debugging output, you'd find that one of the unit tests failed,
since it tested the debug logging code, but the string it expected
and the string it logged differed by a tab vs 2 spaces.
This commit is contained in:
Nick Mathewson 2010-08-06 16:36:23 -04:00
parent ea1ea3d6ee
commit 28f31a4f8d

View File

@ -525,9 +525,9 @@ test_evutil_log(void *ptr)
LOGEQ(_EVENT_LOG_MSG, "Connecting lime to coconut"); LOGEQ(_EVENT_LOG_MSG, "Connecting lime to coconut");
RESET(); RESET();
event_debug(("A millisecond passed! We should log that!")); event_debug(("A millisecond passed! We should log that!"));
#ifdef USE_DEBUG #ifdef USE_DEBUG
LOGEQ(_EVENT_LOG_DEBUG, "A millisecond passed! We should log that!"); LOGEQ(_EVENT_LOG_DEBUG, "A millisecond passed! We should log that!");
#else #else
tt_int_op(logsev,==,0); tt_int_op(logsev,==,0);
tt_ptr_op(logmsg,==,NULL); tt_ptr_op(logmsg,==,NULL);