@@ -186,6 +186,7 @@ describe('Execute: defer directive', () => {
186
186
id : '1' ,
187
187
} ,
188
188
} ,
189
+ pending : [ { path : [ 'hero' ] } ] ,
189
190
hasNext : true ,
190
191
} ,
191
192
{
@@ -241,6 +242,7 @@ describe('Execute: defer directive', () => {
241
242
expectJSON ( result ) . toDeepEqual ( [
242
243
{
243
244
data : { hero : { id : '1' } } ,
245
+ pending : [ { path : [ 'hero' ] } ] ,
244
246
hasNext : true ,
245
247
} ,
246
248
{
@@ -271,6 +273,7 @@ describe('Execute: defer directive', () => {
271
273
expectJSON ( result ) . toDeepEqual ( [
272
274
{
273
275
data : { } ,
276
+ pending : [ { path : [ ] , label : 'DeferQuery' } ] ,
274
277
hasNext : true ,
275
278
} ,
276
279
{
@@ -312,6 +315,7 @@ describe('Execute: defer directive', () => {
312
315
expectJSON ( result ) . toDeepEqual ( [
313
316
{
314
317
data : { } ,
318
+ pending : [ { path : [ ] , label : 'DeferQuery' } ] ,
315
319
hasNext : true ,
316
320
} ,
317
321
{
@@ -361,6 +365,10 @@ describe('Execute: defer directive', () => {
361
365
data : {
362
366
hero : { } ,
363
367
} ,
368
+ pending : [
369
+ { path : [ 'hero' ] , label : 'DeferTop' } ,
370
+ { path : [ 'hero' ] , label : 'DeferNested' } ,
371
+ ] ,
364
372
hasNext : true ,
365
373
} ,
366
374
{
@@ -406,6 +414,7 @@ describe('Execute: defer directive', () => {
406
414
name : 'Luke' ,
407
415
} ,
408
416
} ,
417
+ pending : [ { path : [ 'hero' ] , label : 'DeferTop' } ] ,
409
418
hasNext : true ,
410
419
} ,
411
420
{
@@ -434,6 +443,7 @@ describe('Execute: defer directive', () => {
434
443
name : 'Luke' ,
435
444
} ,
436
445
} ,
446
+ pending : [ { path : [ 'hero' ] , label : 'DeferTop' } ] ,
437
447
hasNext : true ,
438
448
} ,
439
449
{
@@ -459,6 +469,7 @@ describe('Execute: defer directive', () => {
459
469
expectJSON ( result ) . toDeepEqual ( [
460
470
{
461
471
data : { hero : { id : '1' } } ,
472
+ pending : [ { path : [ 'hero' ] , label : 'InlineDeferred' } ] ,
462
473
hasNext : true ,
463
474
} ,
464
475
{
@@ -488,6 +499,7 @@ describe('Execute: defer directive', () => {
488
499
data : {
489
500
hero : { } ,
490
501
} ,
502
+ pending : [ { path : [ 'hero' ] } ] ,
491
503
hasNext : true ,
492
504
} ,
493
505
{
@@ -516,6 +528,10 @@ describe('Execute: defer directive', () => {
516
528
data : {
517
529
hero : { } ,
518
530
} ,
531
+ pending : [
532
+ { path : [ 'hero' ] , label : 'DeferID' } ,
533
+ { path : [ 'hero' ] , label : 'DeferName' } ,
534
+ ] ,
519
535
hasNext : true ,
520
536
} ,
521
537
{
@@ -561,6 +577,10 @@ describe('Execute: defer directive', () => {
561
577
expectJSON ( result ) . toDeepEqual ( [
562
578
{
563
579
data : { } ,
580
+ pending : [
581
+ { path : [ ] , label : 'DeferID' } ,
582
+ { path : [ ] , label : 'DeferName' } ,
583
+ ] ,
564
584
hasNext : true ,
565
585
} ,
566
586
{
@@ -608,6 +628,10 @@ describe('Execute: defer directive', () => {
608
628
data : {
609
629
hero : { } ,
610
630
} ,
631
+ pending : [
632
+ { path : [ ] , label : 'DeferName' } ,
633
+ { path : [ 'hero' ] , label : 'DeferID' } ,
634
+ ] ,
611
635
hasNext : true ,
612
636
} ,
613
637
{
@@ -651,9 +675,11 @@ describe('Execute: defer directive', () => {
651
675
expectJSON ( result ) . toDeepEqual ( [
652
676
{
653
677
data : { } ,
678
+ pending : [ { path : [ ] , label : 'DeferName' } ] ,
654
679
hasNext : true ,
655
680
} ,
656
681
{
682
+ pending : [ { path : [ 'hero' ] , label : 'DeferID' } ] ,
657
683
incremental : [
658
684
{
659
685
data : {
@@ -713,6 +739,20 @@ describe('Execute: defer directive', () => {
713
739
expectJSON ( result ) . toDeepEqual ( [
714
740
{
715
741
data : { hero : { friends : [ { } , { } , { } ] } } ,
742
+ pending : [
743
+ { path : [ 'hero' , 'friends' , 0 ] } ,
744
+ { path : [ 'hero' , 'friends' , 0 ] } ,
745
+ { path : [ 'hero' , 'friends' , 0 ] } ,
746
+ { path : [ 'hero' , 'friends' , 0 ] } ,
747
+ { path : [ 'hero' , 'friends' , 1 ] } ,
748
+ { path : [ 'hero' , 'friends' , 1 ] } ,
749
+ { path : [ 'hero' , 'friends' , 1 ] } ,
750
+ { path : [ 'hero' , 'friends' , 1 ] } ,
751
+ { path : [ 'hero' , 'friends' , 2 ] } ,
752
+ { path : [ 'hero' , 'friends' , 2 ] } ,
753
+ { path : [ 'hero' , 'friends' , 2 ] } ,
754
+ { path : [ 'hero' , 'friends' , 2 ] } ,
755
+ ] ,
716
756
hasNext : true ,
717
757
} ,
718
758
{
@@ -786,6 +826,7 @@ describe('Execute: defer directive', () => {
786
826
} ,
787
827
} ,
788
828
} ,
829
+ pending : [ { path : [ 'hero' ] } ] ,
789
830
hasNext : true ,
790
831
} ,
791
832
{
@@ -825,9 +866,11 @@ describe('Execute: defer directive', () => {
825
866
data : {
826
867
hero : { } ,
827
868
} ,
869
+ pending : [ { path : [ 'hero' ] } ] ,
828
870
hasNext : true ,
829
871
} ,
830
872
{
873
+ pending : [ { path : [ 'hero' , 'nestedObject' , 'deeperObject' ] } ] ,
831
874
incremental : [
832
875
{
833
876
data : {
@@ -901,9 +944,11 @@ describe('Execute: defer directive', () => {
901
944
} ,
902
945
} ,
903
946
} ,
947
+ pending : [ { path : [ 'hero' ] } ] ,
904
948
hasNext : true ,
905
949
} ,
906
950
{
951
+ pending : [ { path : [ 'hero' , 'nestedObject' ] } ] ,
907
952
incremental : [
908
953
{
909
954
data : { bar : 'bar' } ,
@@ -914,6 +959,7 @@ describe('Execute: defer directive', () => {
914
959
hasNext : true ,
915
960
} ,
916
961
{
962
+ pending : [ { path : [ 'hero' , 'nestedObject' , 'deeperObject' ] } ] ,
917
963
incremental : [
918
964
{
919
965
data : { baz : 'baz' } ,
@@ -970,9 +1016,14 @@ describe('Execute: defer directive', () => {
970
1016
} ,
971
1017
} ,
972
1018
} ,
1019
+ pending : [
1020
+ { path : [ 'hero' ] } ,
1021
+ { path : [ 'hero' , 'nestedObject' , 'deeperObject' ] } ,
1022
+ ] ,
973
1023
hasNext : true ,
974
1024
} ,
975
1025
{
1026
+ pending : [ { path : [ 'hero' , 'nestedObject' , 'deeperObject' ] } ] ,
976
1027
incremental : [
977
1028
{
978
1029
data : {
@@ -1043,6 +1094,7 @@ describe('Execute: defer directive', () => {
1043
1094
} ,
1044
1095
} ,
1045
1096
} ,
1097
+ pending : [ { path : [ ] } , { path : [ 'a' , 'b' ] } ] ,
1046
1098
hasNext : true ,
1047
1099
} ,
1048
1100
{
@@ -1092,6 +1144,7 @@ describe('Execute: defer directive', () => {
1092
1144
data : {
1093
1145
a : { } ,
1094
1146
} ,
1147
+ pending : [ { path : [ ] } , { path : [ 'a' ] } ] ,
1095
1148
hasNext : true ,
1096
1149
} ,
1097
1150
{
@@ -1154,6 +1207,7 @@ describe('Execute: defer directive', () => {
1154
1207
data : {
1155
1208
a : { } ,
1156
1209
} ,
1210
+ pending : [ { path : [ ] } , { path : [ 'a' ] } ] ,
1157
1211
hasNext : true ,
1158
1212
} ,
1159
1213
{
@@ -1216,6 +1270,7 @@ describe('Execute: defer directive', () => {
1216
1270
data : {
1217
1271
a : { } ,
1218
1272
} ,
1273
+ pending : [ { path : [ ] } , { path : [ 'a' ] } ] ,
1219
1274
hasNext : true ,
1220
1275
} ,
1221
1276
{
@@ -1305,6 +1360,7 @@ describe('Execute: defer directive', () => {
1305
1360
expectJSON ( result ) . toDeepEqual ( [
1306
1361
{
1307
1362
data : { } ,
1363
+ pending : [ { path : [ ] } ] ,
1308
1364
hasNext : true ,
1309
1365
} ,
1310
1366
{
@@ -1353,6 +1409,7 @@ describe('Execute: defer directive', () => {
1353
1409
friends : [ { name : 'Han' } , { name : 'Leia' } , { name : 'C-3PO' } ] ,
1354
1410
} ,
1355
1411
} ,
1412
+ pending : [ { path : [ 'hero' ] } ] ,
1356
1413
hasNext : true ,
1357
1414
} ,
1358
1415
{
@@ -1388,6 +1445,7 @@ describe('Execute: defer directive', () => {
1388
1445
expectJSON ( result ) . toDeepEqual ( [
1389
1446
{
1390
1447
data : { hero : { friends : [ { name : 'Han' } ] } } ,
1448
+ pending : [ { path : [ 'hero' ] } ] ,
1391
1449
hasNext : true ,
1392
1450
} ,
1393
1451
{
@@ -1424,6 +1482,7 @@ describe('Execute: defer directive', () => {
1424
1482
expectJSON ( result ) . toDeepEqual ( [
1425
1483
{
1426
1484
data : { hero : { friends : [ ] } } ,
1485
+ pending : [ { path : [ 'hero' ] } ] ,
1427
1486
hasNext : true ,
1428
1487
} ,
1429
1488
{
@@ -1456,6 +1515,7 @@ describe('Execute: defer directive', () => {
1456
1515
friends : [ { name : 'Han' } , { name : 'Leia' } , { name : 'C-3PO' } ] ,
1457
1516
} ,
1458
1517
} ,
1518
+ pending : [ { path : [ 'hero' ] } ] ,
1459
1519
hasNext : true ,
1460
1520
} ,
1461
1521
{
@@ -1503,6 +1563,7 @@ describe('Execute: defer directive', () => {
1503
1563
expectJSON ( result ) . toDeepEqual ( [
1504
1564
{
1505
1565
data : { hero : { friends : [ ] } } ,
1566
+ pending : [ { path : [ 'hero' ] } ] ,
1506
1567
hasNext : true ,
1507
1568
} ,
1508
1569
{
@@ -1536,6 +1597,7 @@ describe('Execute: defer directive', () => {
1536
1597
expectJSON ( result ) . toDeepEqual ( [
1537
1598
{
1538
1599
data : { hero : { nestedObject : null } } ,
1600
+ pending : [ { path : [ 'hero' ] } ] ,
1539
1601
hasNext : true ,
1540
1602
} ,
1541
1603
{
@@ -1569,6 +1631,7 @@ describe('Execute: defer directive', () => {
1569
1631
expectJSON ( result ) . toDeepEqual ( [
1570
1632
{
1571
1633
data : { hero : { nestedObject : { name : 'foo' } } } ,
1634
+ pending : [ { path : [ 'hero' ] } ] ,
1572
1635
hasNext : true ,
1573
1636
} ,
1574
1637
{
@@ -1601,6 +1664,7 @@ describe('Execute: defer directive', () => {
1601
1664
expectJSON ( result ) . toDeepEqual ( [
1602
1665
{
1603
1666
data : { hero : { id : '1' } } ,
1667
+ pending : [ { path : [ 'hero' ] } ] ,
1604
1668
hasNext : true ,
1605
1669
} ,
1606
1670
{
@@ -1643,6 +1707,7 @@ describe('Execute: defer directive', () => {
1643
1707
expectJSON ( result ) . toDeepEqual ( [
1644
1708
{
1645
1709
data : { hero : { id : '1' } } ,
1710
+ pending : [ { path : [ 'hero' ] } ] ,
1646
1711
hasNext : true ,
1647
1712
} ,
1648
1713
{
@@ -1721,6 +1786,7 @@ describe('Execute: defer directive', () => {
1721
1786
expectJSON ( result ) . toDeepEqual ( [
1722
1787
{
1723
1788
data : { hero : { id : '1' } } ,
1789
+ pending : [ { path : [ 'hero' ] } ] ,
1724
1790
hasNext : true ,
1725
1791
} ,
1726
1792
{
@@ -1773,9 +1839,15 @@ describe('Execute: defer directive', () => {
1773
1839
data : {
1774
1840
hero : { id : '1' } ,
1775
1841
} ,
1842
+ pending : [ { path : [ 'hero' ] } ] ,
1776
1843
hasNext : true ,
1777
1844
} ,
1778
1845
{
1846
+ pending : [
1847
+ { path : [ 'hero' , 'friends' , 0 ] } ,
1848
+ { path : [ 'hero' , 'friends' , 1 ] } ,
1849
+ { path : [ 'hero' , 'friends' , 2 ] } ,
1850
+ ] ,
1779
1851
incremental : [
1780
1852
{
1781
1853
data : { name : 'slow' , friends : [ { } , { } , { } ] } ,
@@ -1824,9 +1896,15 @@ describe('Execute: defer directive', () => {
1824
1896
data : {
1825
1897
hero : { id : '1' } ,
1826
1898
} ,
1899
+ pending : [ { path : [ 'hero' ] } ] ,
1827
1900
hasNext : true ,
1828
1901
} ,
1829
1902
{
1903
+ pending : [
1904
+ { path : [ 'hero' , 'friends' , 0 ] } ,
1905
+ { path : [ 'hero' , 'friends' , 1 ] } ,
1906
+ { path : [ 'hero' , 'friends' , 2 ] } ,
1907
+ ] ,
1830
1908
incremental : [
1831
1909
{
1832
1910
data : {
0 commit comments