> On 31 Mar 2022, at 16:30, Aleksander Alekseev <aleksan...@timescale.com> > wrote:
Thanks for hacking on increasing test coverage! > While on it, I moved the Asserts() outside of SimpleLruInit(). It didn't seem > to be a right place to check the IsUnderPostmaster value, and complicated the > test implementation. + * + * Returns false if the cache didn't exist before the call, true otherwise. */ -void +bool SimpleLruInit(SlruCtl ctl, const char *name, int nslots, int nlsns, If we're changing the API to make it testable, that should be noted in the comment and how the return value should be interpreted (and when it can be ignored). It also doesn't seem all that appealing that SimpleLruInit can return false on successful function invocation, it makes for a confusing API. -- Daniel Gustafsson https://vmware.com/