protected function setUp()
 {
     parent::setUp();
     // inject some data for testing and cover the absence of web server-type
     // superglobals in the testing CLI context
     $_SERVER['HTTP_HOST'] = 'gcdtech.com';
     $_SERVER['SCRIPT_URI'] = 'http://gcdtech.com/foo';
     $_SERVER['SCRIPT_URL'] = '/foo';
     $_SERVER['HTTPS'] = 'https';
     $_GET = [];
     $_POST = [];
     $_FILES = [];
     $_COOKIE = [];
     $_SESSION = [];
     $_REQUEST = [];
     $this->request = new WebRequest();
 }
Пример #2
0
 protected function setUp()
 {
     parent::setUp();
     $_ENV[$this->testEnvKey] = 42;
     $this->request = new TestRequest();
 }
Пример #3
0
 protected function setUp()
 {
     parent::setUp();
     $this->request = new CliRequest();
 }