Home > The Unit Test Framework > User's guide > Test Output > Test log > Human readable format
PrevNext

Human readable log output format

The human readable log format is designed to closely match an errors description produced by the Microsoft family of C++ compilers. This format allows jumping to the error location, if test module output is redirected into IDE output window. The rest of the log messages are designed to produce the most human friendly description of the events occurring in test module. This is a default format generated by test modules.
可讀的日誌格式設計盡量匹配 Microsoft 族的 C++ 編譯器的錯誤信息。 如果測試模塊輸出重定向到 IDE 的輸出窗口,這種格式可以跳轉到錯誤定位。 日誌信息的其它部分被設計用於盡可能友好地表達測試模塊中發生的事件。 這是測試模塊默認生成的格式。

Here the list of events along with corresponding message and the condition that has to be satisfied for it to appear in the output.
下面是事件相關的信息和條件的列表。

Event : On testing start
Condition : threshold != log_nothing
Output :

Running <total number of test cases> test case(s) 


Event : On testing start
Condition : threshold != log_nothing and show_build_info is set
Output :

Platform: $BOOST_PLATFORM
Compiler: $BOOST_COMPILER
STL     : $BOOST_STDLIB
Boost   : $BOOST_VERSION


Event : On abnormal testing termination
Condition : threshold <= log_messages
Output :

Test is aborted


Event : On test unit start
Condition : threshold <= log_test_units
Output :

Entering test <test unit type> <test unit name>


Event : On test unit end
Condition : threshold <= log_test_units; testing time is reported only if elapsed time is more than 1 mks.
Output :

Leaving test <test unit type> <test unit name>; testing time <value>


Event : On skipped test unit
Condition : threshold <= log_test_units
Output :

Test <test unit type> <test unit name> is skipped


Event : On uncaught C++ exception
Condition : threshold <= log_cpp_exception_errors. Checkpoint message is reported only if provided
Output :

unknown location(0): fatal error in <test case name><explanation>
<last checkpoint location>: last checkpoint: <checkpoint message>


Event : On resumable system error
Condition : threshold <= log_system_errors. Checkpoint message is reported only if provided
Output :

unknown location(0): fatal error in <test case name><explanation>
<last checkpoint location>: last checkpoint: <checkpoint message>


Event : On fatal system error
Condition : threshold <= log_fatal_errors. Checkpoint message is reported only if provided
Output :

unknown location(0): fatal error in <test case name><explanation>
<last checkpoint location>: last checkpoint: <checkpoint message>


Event : On passed test assertion
Condition : threshold <= log_successful_tests
Output :

<assertion location>: info: check<assertion expression> passed


Event : On failed WARNING level test assertion
Condition : threshold <= log_warnings
Output :

<assertion location>: warning in <test case name>: condition <assertion description> is not satisfied


Event : On failed CHECK level test assertion
Condition : threshold <= log_all_errors
Output :

<assertion location>: error in <test case name>: check <assertion description> failed


Event : On failed REQUIRE level test assertion
Condition : threshold <= log_fatal_errors
Output :

<assertion location>: fatal error in <test case name>: critical check <assertion description> failed


Event : On test log message
Condition : threshold <= log_messages
Output :

<Message content>


Advanced testing tools may produce more complicated error messages.
高級的測試工具會產生更複雜的錯誤信息。


PrevUpHomeNext