protected function startLoop()
{
while ($this->loopNextState !== self::LOOP_STATE_STOPPED) {
$this->loopNextState = self::LOOP_STATE_STOPPED;
try {
$this->getLoop()->start();
} catch (Error $ex) {
$this->fail($ex);
} catch (Exception $ex) {
$this->fail($ex);
}
}
}