original_string: public function suiteInit(SuiteEvent $e)
      {
          // Check if PhantomJS should only be started for specific suites.
          if (isset($this->config['suites'])) {
              if (is_string($this->config['suites'])) {
                  $suites = [$this->config['suites']];
              } else {
                  $suites = $this->config['suites'];
              }
  
              // If the current suites aren't in the desired array, return without
              // starting PhantomJS.
              if (!in_array($e->getSuite()->getBaseName(), $suites, true)
                  && !in_array($e->getSuite()->getName(), $suites, true)) {
                  return;
              }
          }
  
          // Start the PhantomJS server.
          $this->startServer();
      }
code: public function suiteInit(SuiteEvent $e)
      {
          // Check if PhantomJS should only be started for specific suites.
          if (isset($this->config['suites'])) {
              if (is_string($this->config['suites'])) {
                  $suites = [$this->config['suites']];
              } else {
                  $suites = $this->config['suites'];
              }
  
              // If the current suites aren't in the desired array, return without
              // starting PhantomJS.
              if (!in_array($e->getSuite()->getBaseName(), $suites, true)
                  && !in_array($e->getSuite()->getName(), $suites, true)) {
                  return;
              }
          }
  
          // Start the PhantomJS server.
          $this->startServer();
      }
code_tokens: public function suiteInit ( SuiteEvent $ e ) { // Check if PhantomJS should only be started for specific suites. if ( isset ( $ this -> config [ 'suites' ] ) ) { if ( is_string ( $ this -> config [ 'suites' ] ) ) { $ suites = [ $ this -> config [ 'suites' ] ] ; } else { $ suites = $ this -> config [ 'suites' ] ; } // If the current suites aren't in the desired array, return without // starting PhantomJS. if ( ! in_array ( $ e -> getSuite ( ) -> getBaseName ( ) , $ suites , true ) && ! in_array ( $ e -> getSuite ( ) -> getName ( ) , $ suites , true ) ) { return ; } } // Start the PhantomJS server. $ this -> startServer ( ) ; }
docstring: Suite Init.
  
  @param \Codeception\Event\SuiteEvent $e
  The event with suite, result and settings.
  
  @throws \Codeception\Exception\ExtensionException
docstring_tokens: Suite Init .