ut: log timestamp to track timeouts better

And improve the logging support in unit-tests to
help troubleshoot issues faster and more accurately.
Also makes the code more readable (hopefully).

Change-Id: I4f8aafb5245e2f774b03231591a74544f9ec84aa
Reviewed-on: https://gerrit.libreoffice.org/48645
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
This commit is contained in:
Ashod Nakashian
2018-01-22 09:11:43 -05:00
committed by Ashod Nakashian
parent 31130989ed
commit 7be98efd93
13 changed files with 269 additions and 182 deletions

View File

@ -12,6 +12,7 @@
#include <cstdint>
#include <cstring>
#include <iomanip>
#include <map>
#include <sstream>
#include <string>
@ -320,7 +321,7 @@ namespace LOOLProtocol
result << Poco::format("%#x", flags);
break;
}
result << " " << length << " bytes";
result << " " << std::setw(3) << length << " bytes";
if (length > 0 &&
((flags & Poco::Net::WebSocket::FRAME_OP_BITMASK) == Poco::Net::WebSocket::FRAME_OP_TEXT ||