Added tests for agent client