fixed test function params bug