fix agent test