diff options
author | sanine <sanine.not@pm.me> | 2022-04-04 17:00:34 -0500 |
---|---|---|
committer | sanine <sanine.not@pm.me> | 2022-04-04 17:00:34 -0500 |
commit | e61a3232f1384876044ab8c0328f42e60d450574 (patch) | |
tree | 0624c96438cde178f2a3ae9b087db833bca06aad /lily-test.h | |
parent | d7f946eecf27448c19f84ed69024840af56436ed (diff) |
add enqueue/dequeue lily_mock_t macros
Diffstat (limited to 'lily-test.h')
-rw-r--r-- | lily-test.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lily-test.h b/lily-test.h index bf0bbae..7a46cd9 100644 --- a/lily-test.h +++ b/lily-test.h @@ -154,15 +154,20 @@ typedef struct lily_mock_t { lily_mock_t * lily_mock_create(); void lily_mock_destroy(lily_mock_t *m); -#define lily_mock_call(m, args) \ +#define lily_mock_call(m, args) \ _lily_mock_call(m, args, LILY_NARGS(args)) void _lily_mock_call(lily_mock_t *m, struct lily_mock_arg_t *args, size_t n_args); -#define lily_get_call(m, args, call_num) \ +#define lily_get_call(m, args, call_num) \ _lily_get_call(m, args, LILY_NARGS(args), call_num) void _lily_get_call(lily_mock_t *m, struct lily_mock_arg_t *args, size_t n_args, unsigned int call_num); +#define lily_store_value(m, type, value) \ + lily_enqueue(m->values, type, value) +#define lily_get_value(m, type, ptr) \ + lily_dequeue(m->values, type, ptr) + #endif |