wrapper function, and test for wrapper function