create new test function to test ws main algo.