How does someone write unit tests for functions that are declared `STATIC`? Clearly there are some functions where the answer is "you don't, leave it alone, there's a good reason we didn't export it." But in cases where there is a lot of logic in a static function, it's a really good idea to test that. In the past, I've seen something like
 
```
#ifdef UNIT_TEST
#define STATIC
#else
#define STATIC static
#endif
```
 
to enable unit tests to call static functions. Would something like this be acceptable upstream?
 
-paul
_._,_._,_

Groups.io Links:

You receive all messages sent to this group.

View/Reply Online (#121238) | | Mute This Topic | New Topic
Your Subscription | Contact Group Owner | Unsubscribe [rebecca@openfw.io]

_._,_._,_