예제 #1
0
 /**
  * @dataProvider setCodeProvider
  */
 public function testSetCode($code, $expectedCode)
 {
     $this->model->terminateOnSend(false);
     $this->model->setCode($code);
     $result = $this->model->sendResponse();
     $this->assertEquals($expectedCode, $result);
 }
예제 #2
0
 /**
  * {@inheritdoc}
  */
 public function catchException(App\Bootstrap $bootstrap, \Exception $exception)
 {
     $this->response->setBody($exception->getMessage());
     $this->response->terminateOnSend(false);
     $this->response->sendResponse();
     return false;
 }
예제 #3
0
 public function testSetBodyNoOutput()
 {
     $this->expectOutputString('');
     $this->model->sendResponse();
 }