| Conditions | 1 |
| Paths | 1 |
| Total Lines | 9 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 23 | public function providingInvalidDataReturnsBadRequest(): void |
||
| 24 | { |
||
| 25 | $resp = $this->callApiWithKey(self::METHOD_PATCH, '/short-urls/invalid', [RequestOptions::JSON => [ |
||
| 26 | 'maxVisits' => 'not_a_number', |
||
| 27 | ]]); |
||
| 28 | ['error' => $error] = $this->getJsonResponsePayload($resp); |
||
| 29 | |||
| 30 | $this->assertEquals(self::STATUS_BAD_REQUEST, $resp->getStatusCode()); |
||
| 31 | $this->assertEquals('INVALID_ARGUMENT', $error); |
||
| 32 | } |
||
| 34 |