diff options
Diffstat (limited to '_testing/core/TestRequest.php')
-rw-r--r-- | _testing/core/TestRequest.php | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/_testing/core/TestRequest.php b/_testing/core/TestRequest.php index c9fc06bf2..fa3ddec90 100644 --- a/_testing/core/TestRequest.php +++ b/_testing/core/TestRequest.php @@ -13,32 +13,32 @@ function ob_start_callback($buffer) { } - /** * Helper class to execute a fake request */ class TestRequest { - var $server = array(); - var $session = array(); - var $get = array(); - var $post = array(); - function getServer($key) { return $this->server[$key]; } - function getSession($key) { return $this->session[$key]; } - function getGet($key) { return $this->get[$key]; } - function getPost($key) { return $this->post[$key]; } + private $server = array(); + private $session = array(); + private $get = array(); + private $post = array(); + + public function getServer($key) { return $this->server[$key]; } + public function getSession($key) { return $this->session[$key]; } + public function getGet($key) { return $this->get[$key]; } + public function getPost($key) { return $this->post[$key]; } - function setServer($key, $value) { $this->server[$key] = $value; } - function setSession($key, $value) { $this->session[$key] = $value; } - function setGet($key, $value) { $this->get[$key] = $value; } - function setPost($key, $value) { $this->post[$key] = $value; } + public function setServer($key, $value) { $this->server[$key] = $value; } + public function setSession($key, $value) { $this->session[$key] = $value; } + public function setGet($key, $value) { $this->get[$key] = $value; } + public function setPost($key, $value) { $this->post[$key] = $value; } /** * Executes the request * - * @return TestResponse response + * @return TestResponse the resulting output of the request */ - function execute() { + public function execute() { // save old environment $server = $_SERVER; $session = $_SESSION; |