Initialize reporter. Setup and listen for runner events

@return void
165146
public function init()
    {
        $this->root = Context::getInstance()->getCurrentSuite();

        $this->eventEmitter->on('runner.start', [$this, 'onRunnerStart']);
        $this->eventEmitter->on('suite.start', [$this, 'onSuiteStart']);
        $this->eventEmitter->on('suite.end', [$this, 'onSuiteEnd']);
        $this->eventEmitter->on('test.passed', [$this, 'onTestPassed']);
        $this->eventEmitter->on('test.failed', [$this, 'onTestFailed']);
        $this->eventEmitter->on('test.pending', [$this, 'onTestPending']);
        $this->eventEmitter->on('runner.end', [$this, 'onRunnerEnd']);
    }
369845
public function initEventLogger()
    {
        $dispatcher = static::getEventDispatcher();

        $logger = $this->newEventLogger();

        $dispatcher->listen('Adldap\Auth\Events\*', function ($eventName, $events) use ($logger) {
            foreach ($events as $event) {
                $logger->auth($event);
            }
        });

        $dispatcher->listen('Adldap\Models\Events\*', function ($eventName, $events) use ($logger) {
            foreach ($events as $event) {
                $logger->model($event);
            }
        });
    }
1023724
protected function init()
    {
        $this->setupContainer();
        $this->configure();
        $this->errorHandling();
        $this->registerServices();

        $this->initialized = true;
    }
1228113
public function init()
    {
        $this->eventEmitter->on('test.passed', [$this, 'onTestPassed']);
        $this->eventEmitter->on('test.failed', [$this, 'onTestFailed']);
        $this->eventEmitter->on('test.pending', [$this, 'onTestPending']);
        $this->eventEmitter->on('runner.end', [$this, 'onRunnerEnd']);
    }
1322719
protected function setupListeners()
    {
        $subscriber = $this->app->make(CommandSubscriber::class);

        $this->app->events->subscribe($subscriber);
    }
830990
public function init()
    {
        if (
            !$this->serviceContainer->isRegistered(ServiceContainer::SERVICE_LOGGER)
            || !($this->getLogger() instanceof LoggerInterface)
        ) {
            $this->setService(ServiceContainer::SERVICE_LOGGER, new NullLogger());
        }
        $this->getControllerDispatcher()->setLogger($this->getLogger());
    }
825894
private function runInitMethods(): void
    {
        $reflectionClass = self::getDoctrineStaticMeta()->getReflectionClass();
        $methods         = $reflectionClass->getMethods(\ReflectionMethod::IS_PRIVATE);
        foreach ($methods as $method) {
            if ($method instanceof ReflectionMethod) {
                $method = $method->getName();
            }
            if (\ts\stringContains($method, UsesPHPMetaDataInterface::METHOD_PREFIX_INIT)
                && \ts\stringStartsWith($method, UsesPHPMetaDataInterface::METHOD_PREFIX_INIT)
            ) {
                $this->$method();
            }
        }
    }
428444
protected function init() {
        $reporttype = explode('\\', $this->eventname);
        $shorttype = explode('_', $reporttype[1]);
        $this->reporttype = $shorttype[1];

        $this->data['crud'] = 'r';
        $this->data['edulevel'] = self::LEVEL_TEACHING;
    }
27897
protected function init()
	{
		parent::init();
		if(empty($_SERVER['argv']))
			die('This script must be run from the command line.');
		$this->_runner=$this->createCommandRunner();
		$this->_runner->commands=$this->commandMap;
		$this->_runner->addCommands($this->getCommandPath());
	}
636035
public function initialize() {
        $this->handler = curl_init();

        $this->setOption(CURLOPT_URL, $this->requestUrl)
             ->setOption(CURLOPT_VERBOSE, 0)
             ->setOption(CURLOPT_HEADER, 0);
    }
207750
public function on_start()
    {
        $this->registerServiceProvider();
        $this->registerParsers();
        $this->app->make('director')->addSubscriber($this->app->make(EventSubscriber::class));
        if ($this->app->isRunThroughCommandLineInterface()) {
            $this->registerCLICommands();
        } else {
            $this->registerAssets();
            $this->registerRoutes();
        }
    }
225916
public function init()
    {
        if (Console::isCli()) {
            // fix for fcgi
            defined('STDIN') or define('STDIN', fopen('php://stdin', 'r'));

            if (!isset($_SERVER['argv'])) {
                die('This script must be run from the command line.');
            }
            $this->_runner = $this->createCommandRunner();
            $this->_runner->commands = $this->commandMap;
            $this->_runner->addCommands($this->getCommandPath());

            $env = @getenv('CONSOLE_COMMANDS');
            if (!empty($env)) {
                $this->_runner->addCommands($env);
            }

            foreach ($this->modules as $name => $settings) {
                $modulePath = Alias::get("Modules." . $name . ".Commands");
                if ($modulePath) {
                    $this->_runner->addCommands($modulePath);
                }
            }
        } else {
            // preload 'request' so that it has chance to respond to onBeginRequest event.
            $this->getComponent('request');
        }
    }
771299
public function init()
    {
        if (TIGA_DEBUG == true && !$this->app->isConsole()) {
            $whoops = new \Whoops\Run();

            if ($this->app['request']->isJson()) {
                $whoops->pushHandler(new \Whoops\Handler\JsonResponseHandler());
            } else {
                $whoops->pushHandler(new \Whoops\Handler\PrettyPageHandler());
            }

            $whoops->register();
        }
    }
283853
protected function init()
    {
        if(!\extension_loaded('inotify'))
        {
            throw new \RuntimeException('the extension inotify is not installed');
        }
        $this->handler = \inotify_init();
        stream_set_blocking($this->handler, 0);

        $this->excludeRule = implode('|', array_map('\Imi\Util\Imi::parseRule', $this->excludePaths));
        foreach($this->includePaths as $path)
        {
            \inotify_add_watch($this->handler, $path, $this->mask);
            $directory = new \RecursiveDirectoryIterator($path, \FilesystemIterator::KEY_AS_PATHNAME | \FilesystemIterator::CURRENT_AS_FILEINFO);
            $iterator = new \RecursiveIteratorIterator($directory);
            if('' === $this->excludeRule)
            {
                foreach($iterator as $fileName => $fileInfo)
                {
                    $filePath = dirname($fileName);
                    if(!isset($this->paths[$filePath]))
                    {
                        $this->paths[$filePath] = \inotify_add_watch($this->handler, $filePath, $this->mask);
                    }
                }
            }
            else
            {
                $rule = "/^(?!{$this->excludeRule}).+$/i";
                $regex = new \RegexIterator($iterator, $rule, \RecursiveRegexIterator::GET_MATCH);
                foreach ($regex as $item)
                {
                    $filePath = dirname($item[0]);
                    if(!isset($this->paths[$filePath]))
                    {
                        $this->paths[$filePath] = \inotify_add_watch($this->handler, $filePath, $this->mask);
                    }
                }
            }
        }
    }
41438
public function init()
    {
        $this->header('Content-Type: text/plain');

        $this->proc = new \PHPDaemon\Core\ShellCommand();
        $this->proc->onReadData(function ($stream, $data) {
            echo $data;
        });
        $this->proc->onEOF(function ($stream) {
            $this->wakeup();
        });
        $this->proc->nice(256);
        $this->proc->execute('/bin/ls -l /tmp');
    }
269205
protected function __init()
    {
        $events = $this->event();

        // --- How to resolve requested module --------------------------------\
        // --------------------------------------------------------------------\
        ## resolve to module by looking on ModuleName\Module class
        ## also set options on array modules, like ['module'=>$opts]
        $events->on(
            ModuleManagerEvents\EventModuleResolve::EVENT_NAME
            , new ModuleManager\Events\ModuleResolve\ListenerResolverDefault
            , 100
        );

        $events->on(
            ModuleManagerEvents\EventModuleResolve::EVENT_NAME
            , new ModuleManager\Events\ModuleResolve\ListenerResolverDirectory
            , 90
        );

        // --- Features Call Immanently after resolve module object -----------\
        // --------------------------------------------------------------------\
        $events->on(
            ModuleManagerEvents\EventModuleInitialize::EVENT_NAME
            , new ModuleManager\Events\ModuleInitialize\ListenerInitInitialization
            , 1000
        );

        $events->on(
            ModuleManagerEvents\EventModuleInitialize::EVENT_NAME
            , new ModuleManager\Events\ModuleInitialize\ListenerInitServices
            , 900
        );

        ## register modules services and actions
        $events->on(
            ModuleManagerEvents\EventModuleInitialize::EVENT_NAME
            , new ModuleManager\Events\ModuleInitialize\ListenerInitNestedContainer
        );


        // --- Features Call After Whole Modules Initialized        -----------\
        // --------------------------------------------------------------------\
        // Event Param: $module_manager

        # Register Actions
        #
        // Note: Actions do not access to Initialized Configs...
        //       actions on registration just must register itself and no need any instantiate
        $events->on(
            EventHeapOfModuleManager::EVENT_MODULES_POSTLOAD
            , new ModuleManager\Events\ModulesPostLoad\ListenerRegisterActions
            , -100
        );

        # Instantiate Merged Config instance() services
        $events->on(
            EventHeapOfModuleManager::EVENT_MODULES_POSTLOAD
            , new ModuleManager\Events\ModulesPostLoad\ListenerInstantiateMergedConfig
            , -500
        );

        # Resolve registered services to module
        $events->on(
            EventHeapOfModuleManager::EVENT_MODULES_POSTLOAD
            , new ModuleManager\Events\ModulesPostLoad\ListenerGrabRegisteredServices
            , -1000
        );

        ## attach application events listener
        $events->on(
            EventHeapOfModuleManager::EVENT_MODULES_POSTLOAD
            , new ModuleManager\Events\ModuleInitialize\ListenerInitSapiEvents
            , -10000
        );
    }
617827
public function initialize()
    {
        if ($this->isInitialize) {
            return ;
        }

        $this->isInitialize = true;

        $this->getEventManager()->trigger(self::EVENT_INITIALIZE, $this);
    }