|
Zephyr API Documentation 4.3.0-rc1
A Scalable Open Source RTOS
|
This module provides extensions to FFF for simplifying the configuration and usage of fakes. More...
Macros | |
| #define | RETURN_HANDLED_CONTEXT(FUNCNAME, CONTEXTTYPE, RESULTFIELD, CONTEXTPTRNAME, HANDLERBODY) |
| Wrap custom fake body to extract defined context struct. | |
This module provides extensions to FFF for simplifying the configuration and usage of fakes.
| #define RETURN_HANDLED_CONTEXT | ( | FUNCNAME, | |
| CONTEXTTYPE, | |||
| RESULTFIELD, | |||
| CONTEXTPTRNAME, | |||
| HANDLERBODY ) |
#include <zephyr/fff_extensions.h>
Wrap custom fake body to extract defined context struct.
Add extension macro for simplified creation of fake functions needing call-specific context data.
This macro enables a fake to be implemented as follows and requires no familiarity with the inner workings of FFF.
| FUNCNAME | Name of function being faked |
| CONTEXTTYPE | type of custom defined fake context struct |
| RESULTFIELD | name of field holding the return type & value |
| CONTEXTPTRNAME | expected name of pointer to custom defined fake context struct |
| HANDLERBODY | in-line custom fake handling logic |