Add log-related command-line options to unit tests.

You can now specify the following when running a unit test:
  -p, --print-logs
      Print the log messages as they are being generated.
  -o, --log-file=FILE
      Print all log messages to FILE instead of standard output

Also, when a test fails the messages no longer get dumped to standard
output. They only get dumped when specifying --print-logs.

Change-Id: Icc265734f302c27c24829409ca6f7c8fce2979d4
diff --git a/aos/common/queue_testutils.h b/aos/common/queue_testutils.h
index 3c7a0a4..fb0ffcd 100644
--- a/aos/common/queue_testutils.h
+++ b/aos/common/queue_testutils.h
@@ -35,6 +35,16 @@
 // being run.
 void PreventExit();
 
+// Redirect the messages enabled by EnableTestLogging() function to a file.
+// By default the messages are printed to standard output.
+void SetLogFileName(const char* filename);
+
+// Force the messages to be printed as they are handled by the logging
+// framework. This can be useful for tests that hang where no messages would
+// otherwise be printed. This is also useful for tests that do pass, but where
+// we want to use graphing tools to verify what's happening.
+void ForcePrintLogsDuringTests();
+
 }  // namespace testing
 }  // namespace common
 }  // namespace aos