also looking at this
Add More Tests
#42
6 files
+170
-26
| @@ -51,12 +51,14 @@ class Favorite | ||
| 51 | 51 | return $this->all(); |
| 52 | 52 | } |
| 53 | 53 | |
| 54 | if (! is_int($id)) { | |
| 55 | throw new InvalidFormatException(); | |
| 56 | } | |
| 57 | ||
| 58 | 54 | $ids = is_array($id) ? $id : func_get_args(); |
| 59 | 55 | |
| 56 | foreach ($ids as $id) { | |
| 57 | if (! is_int($id)) { | |
| 58 | throw new InvalidFormatException(); | |
| 59 | } | |
| 60 | } | |
| 61 | ||
| 60 | 62 | return $this->client->request('GET', 'favorites', ['favorite_ids' => $ids]); |
| 61 | 63 | } |
| 62 | 64 | |