Changeset 1433ecda in mainline for uspace/lib/pcut/src/report/tap.c
- Timestamp:
- 2018-04-04T15:42:37Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2c4e1cc
- Parents:
- 47b2d7e3
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/pcut/src/report/tap.c
r47b2d7e3 r1433ecda 55 55 * @param all_items Start of the list with all items. 56 56 */ 57 static void tap_init(pcut_item_t *all_items) { 57 static void tap_init(pcut_item_t *all_items) 58 { 58 59 int tests_total = pcut_count_tests(all_items); 59 60 test_counter = 0; … … 67 68 * @param suite Suite that just started. 68 69 */ 69 static void tap_suite_start(pcut_item_t *suite) { 70 static void tap_suite_start(pcut_item_t *suite) 71 { 70 72 tests_in_suite = 0; 71 73 failed_tests_in_suite = 0; … … 78 80 * @param suite Suite that just ended. 79 81 */ 80 static void tap_suite_done(pcut_item_t *suite) { 82 static void tap_suite_done(pcut_item_t *suite) 83 { 81 84 if (failed_tests_in_suite == 0) { 82 85 printf("#> Finished suite %s (passed).\n", 83 86 suite->name); 84 87 } else { 85 88 printf("#> Finished suite %s (failed %d of %d).\n", 86 89 suite->name, failed_tests_in_suite, tests_in_suite); 87 90 } 88 91 } … … 94 97 * @param test Test that is started. 95 98 */ 96 static void tap_test_start(pcut_item_t *test) { 99 static void tap_test_start(pcut_item_t *test) 100 { 97 101 PCUT_UNUSED(test); 98 102 … … 106 110 * @param prefix Prefix for each new line, such as comment character. 107 111 */ 108 static void print_by_lines(const char *message, const char *prefix) { 112 static void print_by_lines(const char *message, const char *prefix) 113 { 109 114 char *next_line_start; 110 115 if ((message == NULL) || (message[0] == 0)) { … … 132 137 */ 133 138 static void tap_test_done(pcut_item_t *test, int outcome, 134 const char *error_message, const char *teardown_error_message, 135 const char *extra_output) { 139 const char *error_message, const char *teardown_error_message, 140 const char *extra_output) 141 { 136 142 const char *test_name = test->name; 137 143 const char *status_str = NULL; … … 166 172 167 173 /** Report testing done. */ 168 static void tap_done(void) { 174 static void tap_done(void) 175 { 169 176 if (failed_test_counter == 0) { 170 177 printf("#> Done: all tests passed.\n");
Note:
See TracChangeset
for help on using the changeset viewer.