diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2020-06-26 07:44:55 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2020-07-23 09:27:47 +0200 |
commit | 63e42784290b4bb103fbb3f64bad23dc9edef9f3 (patch) | |
tree | ff8d04a0fe555005b7bd62df12ff98d1d58d8f4a /cpukit/include/rtems/test.h | |
parent | libtest: Add push/pop fixture support (diff) | |
download | rtems-63e42784290b4bb103fbb3f64bad23dc9edef9f3.tar.bz2 |
libtest: Add T_get_scope()
Update #3199.
Diffstat (limited to 'cpukit/include/rtems/test.h')
-rw-r--r-- | cpukit/include/rtems/test.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/cpukit/include/rtems/test.h b/cpukit/include/rtems/test.h index 04f92dd1f4..09afc29593 100644 --- a/cpukit/include/rtems/test.h +++ b/cpukit/include/rtems/test.h @@ -2243,6 +2243,29 @@ void *T_push_fixture(T_fixture_node *, const T_fixture *); void T_pop_fixture(void); +/** + * @brief Gets the scope for nested fixtures. + * + * This function should help implementing scope fixture methods. The parameter + * layout allows efficient code generation for this method. + * + * @param desc is the description table. It shall be a NULL-terminated array + * which references arrays of descriptive strings. + * + * @param buf is the buffer for the scope string. + * + * @param n is the size of the scope buffer in characters. + * + * @param second_indices is an array of indices defining which descriptive + * string is used for each entry in the description table. + */ +void T_get_scope( + const char * const * const *desc, + char *buf, + size_t n, + const size_t *second_indices +); + #ifdef __rtems__ #define T_TEST_CASE_FIXTURE(name, fixture) \ void T_case_body_##name(void); \ |