@@ -159,12 +159,6 @@ public function testItWillSerializeToJsonApiAComplexObject()
159
159
"self":{
160
160
"href":"http://example.com/posts/9"
161
161
},
162
- "first":{
163
- "href":"http://example.com/posts/1"
164
- },
165
- "next":{
166
- "href":"http://example.com/posts/10"
167
- },
168
162
"comments":{
169
163
"href":"http://example.com/posts/9/comments"
170
164
}
@@ -193,14 +187,16 @@ public function testItWillSerializeToJsonApiAComplexObject()
193
187
]
194
188
);
195
189
$ transformer ->addMeta ('is_devel ' , true );
196
- $ transformer ->setSelfUrl ('http://example.com/posts/9 ' );
197
- $ transformer ->setFirstUrl ('http://example.com/posts/1 ' );
198
- $ transformer ->setNextUrl ('http://example.com/posts/10 ' );
190
+
191
+ print_r (\json_decode ((new JsonApiSerializer ($ transformer ))->serialize ($ post ), true ));
199
192
200
193
$ this ->assertEquals (
201
194
\json_decode ($ expected , true ),
202
195
\json_decode ((new JsonApiSerializer ($ transformer ))->serialize ($ post ), true )
203
196
);
197
+
198
+
199
+ die ();
204
200
}
205
201
206
202
/**
@@ -303,13 +299,11 @@ public function testItWillSerializeToJsonApiAComplexObjectAndFilterIncluded()
303
299
]
304
300
);
305
301
$ transformer ->addMeta ('is_devel ' , true );
306
- $ transformer ->setSelfUrl ('http://example.com/posts/9 ' );
307
- $ transformer ->setFirstUrl ('http://example.com/posts/1 ' );
308
- $ transformer ->setNextUrl ('http://example.com/posts/10 ' );
309
302
310
303
$ included = new Included ();
311
304
$ included ->add ('user.post ' );
312
305
306
+
313
307
$ this ->assertEquals (
314
308
\json_decode ($ expected , true ),
315
309
\json_decode ((new JsonApiSerializer ($ transformer ))->serialize ($ post , new Fields (), $ included ), true )
@@ -381,12 +375,6 @@ public function testItWillSerializeToJsonApiAComplexObjectAndFilterIncludedSpeci
381
375
"self":{
382
376
"href":"http://example.com/posts/9"
383
377
},
384
- "first":{
385
- "href":"http://example.com/posts/1"
386
- },
387
- "next":{
388
- "href":"http://example.com/posts/10"
389
- },
390
378
"comments":{
391
379
"href":"http://example.com/posts/9/comments"
392
380
}
@@ -415,9 +403,6 @@ public function testItWillSerializeToJsonApiAComplexObjectAndFilterIncludedSpeci
415
403
]
416
404
);
417
405
$ transformer ->addMeta ('is_devel ' , true );
418
- $ transformer ->setSelfUrl ('http://example.com/posts/9 ' );
419
- $ transformer ->setFirstUrl ('http://example.com/posts/1 ' );
420
- $ transformer ->setNextUrl ('http://example.com/posts/10 ' );
421
406
422
407
$ included = new Included ();
423
408
$ included ->add ('user ' );
@@ -457,12 +442,6 @@ public function testItWillSerializeToJsonApiAComplexObjectAndFilterFields()
457
442
"self":{
458
443
"href":"http://example.com/posts/9"
459
444
},
460
- "first":{
461
- "href":"http://example.com/posts/1"
462
- },
463
- "next":{
464
- "href":"http://example.com/posts/10"
465
- },
466
445
"comments":{
467
446
"href":"http://example.com/posts/9/comments"
468
447
}
@@ -491,9 +470,6 @@ public function testItWillSerializeToJsonApiAComplexObjectAndFilterFields()
491
470
]
492
471
);
493
472
$ transformer ->addMeta ('is_devel ' , true );
494
- $ transformer ->setSelfUrl ('http://example.com/posts/9 ' );
495
- $ transformer ->setFirstUrl ('http://example.com/posts/1 ' );
496
- $ transformer ->setNextUrl ('http://example.com/posts/10 ' );
497
473
498
474
$ fields = new Fields ();
499
475
$ fields ->addField ('post ' , 'title ' );
0 commit comments