Implementing test function.