コード例 #1
0
 public function sendHeaders()
 {
     $headers = $this->response->getHeaders();
     foreach ($headers as $header) {
         header($header);
     }
 }
コード例 #2
0
 public function testRestPesonseObj()
 {
     $response = WRestResponse::factory('json');
     $this->assertTrue($response instanceof WRestResponse);
     $this->assertTrue($response instanceof JsonResponse);
     $this->assertTrue(static::$response instanceof WRestResponse);
     //test default param for new obj
     $this->assertEmpty(static::$response->getBody());
     $this->assertEquals(static::$response->getStatus(), 200);
 }