__construct() public method

Constructor.
public __construct ( Symfony\Component\HttpKernel\HttpKernelInterface $kernel, array $server = [], Symfony\Component\BrowserKit\History $history = null, Symfony\Component\BrowserKit\CookieJar $cookieJar = null )
$kernel Symfony\Component\HttpKernel\HttpKernelInterface An HttpKernel instance
$server array The server parameters (equivalent of $_SERVER)
$history Symfony\Component\BrowserKit\History A History instance to store the browser history
$cookieJar Symfony\Component\BrowserKit\CookieJar A CookieJar instance to store the cookies
Esempio n. 1
0
 /**
  * Constructor.
  *
  * @param Application $app
  */
 public function __construct(Application $app)
 {
     $this->app = $app;
     $this->httpKernel = $this->app->make('Illuminate\\Contracts\\Http\\Kernel');
     $this->httpKernel->bootstrap();
     $this->app->boot();
     parent::__construct($this);
 }
Esempio n. 2
0
 /**
  * Constructor.
  *
  * @param \Codeception\Module\Laravel4 $module
  */
 public function __construct($module)
 {
     $this->module = $module;
     $this->initialize();
     parent::__construct($this->kernel);
     // Parent constructor defaults to not following redirects
     $this->followRedirects(true);
 }
Esempio n. 3
0
 /**
  * Constructor.
  *
  * @param \Symfony\Component\HttpKernel\Kernel  $kernel     A booted HttpKernel instance
  * @param array                                 $services   An injected services
  * @param boolean                               $rebootable
  */
 public function __construct(\Symfony\Component\HttpKernel\Kernel $kernel, array $services = [], $rebootable = true)
 {
     parent::__construct($kernel);
     $this->followRedirects(true);
     $this->rebootable = (bool) $rebootable;
     $this->persistentServices = $services;
     $this->rebootKernel();
 }
Esempio n. 4
0
 /**
  * Constructor.
  * @param \Codeception\Module\Laravel5 $module
  */
 public function __construct($module)
 {
     $this->module = $module;
     $this->initialize();
     $components = parse_url($this->app['config']->get('app.url', 'http://localhost'));
     $host = isset($components['host']) ? $components['host'] : 'localhost';
     parent::__construct($this->app, ['HTTP_HOST' => $host]);
     // Parent constructor defaults to not following redirects
     $this->followRedirects(true);
 }
Esempio n. 5
0
 /**
  * Constructor.
  *
  * @param Application $app
  */
 public function __construct(Application $app)
 {
     $this->app = $app;
     $this->httpKernel = $this->app->make('Illuminate\\Contracts\\Http\\Kernel');
     $this->httpKernel->bootstrap();
     $this->app->boot();
     $url = $this->app->config->get('app.url', 'http://localhost');
     $this->app->instance('request', Request::createFromBase(SyfmonyRequest::create($url)));
     $components = parse_url($url);
     $host = isset($components['host']) ? $components['host'] : 'localhost';
     parent::__construct($this, ['HTTP_HOST' => $host]);
     $this->followRedirects(true);
     // Parent constructor sets this to false by default
 }
Esempio n. 6
0
 /**
  * Constructor.
  *
  * @param \Codeception\Module\Laravel5 $module
  */
 public function __construct($module)
 {
     $this->module = $module;
     $this->exceptionHandlingDisabled = $this->module->config['disable_exception_handling'];
     $this->middlewareDisabled = $this->module->config['disable_middleware'];
     $this->eventsDisabled = $this->module->config['disable_events'];
     $this->initialize();
     $components = parse_url($this->app['config']->get('app.url', 'http://localhost'));
     if (array_key_exists('url', $this->module->config)) {
         $components = parse_url($this->module->config['url']);
     }
     $host = isset($components['host']) ? $components['host'] : 'localhost';
     parent::__construct($this->app, ['HTTP_HOST' => $host]);
     // Parent constructor defaults to not following redirects
     $this->followRedirects(true);
 }
Esempio n. 7
0
 /**
  * Constructor.
  *
  * @param Application $app
  */
 public function __construct(Application $app)
 {
     $this->app = $app;
     parent::__construct($this);
 }
Esempio n. 8
0
 /**
  * {@inheritdoc}
  */
 public function __construct(KernelInterface $kernel, array $server = array(), History $history = null, CookieJar $cookieJar = null)
 {
     parent::__construct($kernel, $server, $history, $cookieJar);
 }
Esempio n. 9
0
 /**
  * Constructor.
  *
  * @param HttpKernelInterface $kernel    A Kernel instance
  * @param array               $server    The server parameters (equivalent of $_SERVER)
  * @param History             $history   A History instance to store the browser history
  * @param CookieJar           $cookieJar A CookieJar instance to store the cookies
  */
 public function __construct(HttpKernelInterface $kernel, array $server = array(), History $history = null, CookieJar $cookieJar = null)
 {
     parent::__construct($kernel, $server, $history, $cookieJar);
     $this->container = $kernel->getContainer();
 }