| 1 | <?php |
||
| 6 | class ResponseTest extends \PHPUnit_Framework_TestCase { |
||
| 7 | |||
| 8 | public $response; |
||
| 9 | |||
| 10 | public function setup(){ |
||
| 13 | |||
| 14 | // set HTTP response code and test |
||
| 15 | public function testSetResponseCode(){ |
||
| 19 | |||
| 20 | // set HTTP code and text and test |
||
| 21 | public function testSetResponseCodeAndText(){ |
||
| 26 | |||
| 27 | // set a redirect command and test code/location separately |
||
| 28 | public function testRedirectLocationAndCode(){ |
||
| 33 | |||
| 34 | /** |
||
| 35 | * use the exception anotation to test an exception triggered by invalid |
||
| 36 | * HTTP code value |
||
| 37 | * @expectedException \LogicException |
||
| 38 | * @expectedExceptionMessage 987654321 is unsuported HTTP status code |
||
| 39 | */ |
||
| 40 | public function testSetStatusThrowsLogicExceptionOnInvalidStatusCodeRange(){ |
||
| 43 | |||
| 44 | } |