Tests: Mitigate race condition in test_clientagent with set_state
Merge pull request #132 from Astron/fix_test_clientagent

Tests: Mitigate race condition in test_clientagent with set_state