protected function getLoopMock()
{
$this->mockGenerator->orphanize('__construct');
$this->mockGenerator->shuntParentClassCalls();
$mock = new \mock\React\EventLoop\StreamSelectLoop();
$mock->getMockController()->addPeriodicTimer = function ($time, $function) {
$function();
};
return $mock;
}