[SJS-162][TEST]: Write tests for _wait() function