public function testPostRawDataRequest() { echo __METHOD__ . "\n"; $r = new HttpRequest($this->url . 'post'); $r->setQueryString($this->params); $r->setHeader($this->headers); $data = $r->post($this->jsonParams, HttpRequest::RAW_DATA); $this->assertEquals(true, json_decode($data->getBody(), true)['json'] != ''); $this->assertEquals(200, $data->getStatusCode()); }
public function post($data = []) { $this->request->post($data); //return $this->explorer(); }