fix test function?