Beispiel #1
0
 /**
  * parses request input
  * @return array
  */
 public function getRequestData()
 {
     $data = $this->request->getInput();
     if (is_null($data) || !strlen($data)) {
         $data = [];
     }
     return is_string($data) ? json_decode($data, true) : $data;
 }
Beispiel #2
0
 public function testInputGetterAndSetter()
 {
     $input = 'testing';
     $this->req->setInput($input);
     $this->assertEquals($input, $this->req->getInput());
 }