diff options
author | Giovanni Di Sirio <gdisirio@gmail.com> | 2017-10-24 19:00:39 +0000 |
---|---|---|
committer | Giovanni Di Sirio <gdisirio@gmail.com> | 2017-10-24 19:00:39 +0000 |
commit | 3f72c7787eb9ad2e3bf846b7184fe283ab8a19c2 (patch) | |
tree | 30e28c20a308d23bffdb29dfd6ae9a14b2778150 | |
parent | 276a56324dec125d1b431a0b1a02db8e15b27070 (diff) | |
download | ChibiOS-3f72c7787eb9ad2e3bf846b7184fe283ab8a19c2.tar.gz ChibiOS-3f72c7787eb9ad2e3bf846b7184fe283ab8a19c2.tar.bz2 ChibiOS-3f72c7787eb9ad2e3bf846b7184fe283ab8a19c2.zip |
Improved reports look.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@10899 35acf78f-673a-0410-8e92-d51de3d6d3f4
-rw-r--r-- | test/lib/ch_test.c | 14 | ||||
-rw-r--r-- | test/lib/ch_test.h | 7 |
2 files changed, 19 insertions, 2 deletions
diff --git a/test/lib/ch_test.c b/test/lib/ch_test.c index f4612e421..ef5883108 100644 --- a/test/lib/ch_test.c +++ b/test/lib/ch_test.c @@ -94,6 +94,14 @@ static void print_line(void) { streamWrite(test_chp, (const uint8_t *)"\r\n", 2);
}
+static void print_fat_line(void) {
+ unsigned i;
+
+ for (i = 0; i < 76; i++)
+ streamPut(test_chp, '=');
+ streamWrite(test_chp, (const uint8_t *)"\r\n", 2);
+}
+
/*===========================================================================*/
/* Module exported functions. */
/*===========================================================================*/
@@ -255,12 +263,14 @@ msg_t test_execute(BaseSequentialStream *stream, const testsuite_t *tsp) { test_global_fail = false;
tseq = 0;
while (tsp->sequences[tseq] != NULL) {
- print_line();
- test_print("--- Test Sequence ");
+#if TEST_SHOW_SEQUENCES == TRUE
+ print_fat_line();
+ test_print("=== Test Sequence ");
test_printn(tseq + 1);
test_print(" (");
test_print(tsp->sequences[tseq]->name);
test_println(")");
+#endif
tcase = 0;
while (tsp->sequences[tseq]->cases[tcase] != NULL) {
print_line();
diff --git a/test/lib/ch_test.h b/test/lib/ch_test.h index 236b6ed23..20d62332b 100644 --- a/test/lib/ch_test.h +++ b/test/lib/ch_test.h @@ -47,6 +47,13 @@ #define TEST_DELAY_BETWEEN_TESTS 200
#endif
+/**
+ * @brief Delay inserted between test cases.
+ */
+#if !defined(TEST_SHOW_SEQUENCES) || defined(__DOXYGEN__)
+#define TEST_SHOW_SEQUENCES TRUE
+#endif
+
/*===========================================================================*/
/* Derived constants and error checks. */
/*===========================================================================*/
|