1 /* 2 * Copyright (c) 2022 Nordic Semiconductor ASA 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7 #include <zephyr/fff.h> 8 #include <zephyr/kernel.h> 9 #include <zephyr/sys_clock.h> 10 11 /* List of fakes used by this unit tester */ 12 #define KERNEL_FFF_FAKES_LIST(FAKE) \ 13 FAKE(z_timeout_remaining) \ 14 FAKE(k_work_schedule) \ 15 FAKE(k_work_cancel_delayable_sync) \ 16 FAKE(k_work_init_delayable) 17 18 DECLARE_FAKE_VALUE_FUNC(k_ticks_t, z_timeout_remaining, const struct _timeout *); 19 DECLARE_FAKE_VALUE_FUNC(int, k_work_schedule, struct k_work_delayable *, k_timeout_t); 20 DECLARE_FAKE_VALUE_FUNC(bool, k_work_cancel_delayable_sync, struct k_work_delayable *, 21 struct k_work_sync *); 22 DECLARE_FAKE_VOID_FUNC(k_work_init_delayable, struct k_work_delayable *, k_work_handler_t); 23 DECLARE_FAKE_VALUE_FUNC(int, k_work_submit, struct k_work *); 24