Notes
Jump to navigation
Jump to search
Notes
Note macros provide a simple means to add annotations attached to the currently executing test case. These annotations are added to the test report info with a level of either Error, Warning, or Info according to the macro that is used.
Error Annotation | |
srNOTE_ERROR(message, ...) | message is a pointer to a null-terminated format string ... variable list matching the format string |
Warning Annotation | |
srNOTE_WARN(message, ...) | message is a pointer to a null-terminated format string ... variable list matching the format string |
Info Annotation | |
srNOTE_INFO(message, ...) | message is a pointer to a null-terminated format string ... variable list matching the format string |
- versions of these log macros also exist for use with dynamically generated test cases. To use these macros, just append _DYN to the macro names shown above and then pass the explicit testCaseHandle_t item as the first argument to the macros.
- The maximum length of the message string approximately 1000 characters. If the maximum length is exceeded, the message string is truncated.
Example
srNOTE_ERROR("This is an error message.");
srNOTE_WARN("This is a warning message with format string %d.", 123);
srNOTE_INFO("This is an info message with format string %s and %s.", "this", "that");