os-wrappers-test: assert closure is not NULL before invoking it

Signed-off-by: U. Artie Eoff <ullysses.a.eoff@intel.com>