| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,27 @@ |
| 1 |
+<?php |
|
| 2 |
+ |
|
| 3 |
+namespace Telnyx; |
|
| 4 |
+ |
|
| 5 |
+/** |
|
| 6 |
+ * @internal |
|
| 7 |
+ * @covers \Telnyx\ApiResponse |
|
| 8 |
+ */ |
|
| 9 |
+final class ApiResponseTest extends \Telnyx\TestCase |
|
| 10 |
+{
|
|
| 11 |
+ public function testConstruct() |
|
| 12 |
+ {
|
|
| 13 |
+ $obj = [ |
|
| 14 |
+ 'body' => 'body', |
|
| 15 |
+ 'code' => 'code', |
|
| 16 |
+ 'headers' => 'header', |
|
| 17 |
+ 'json' => 'json' |
|
| 18 |
+ ]; |
|
| 19 |
+ |
|
| 20 |
+ $class = new \Telnyx\ApiResponse($obj['body'], $obj['code'], $obj['headers'], $obj['json']); |
|
| 21 |
+ |
|
| 22 |
+ static::assertSame($obj['body'], $class->body); |
|
| 23 |
+ static::assertSame($obj['code'], $class->code); |
|
| 24 |
+ static::assertSame($obj['headers'], $class->headers); |
|
| 25 |
+ static::assertSame($obj['json'], $class->json); |
|
| 26 |
+ } |
|
| 27 |
+} |