@@ -497,7 +497,7 @@ describeSpec('Writes:', [], () => {
497
497
) ;
498
498
} ) ;
499
499
500
- specTest ( 'Held writes are not re-sent.' , [ ] , ( ) => {
500
+ specTest ( 'Writes are not re-sent.' , [ ] , ( ) => {
501
501
const query = Query . atPath ( path ( 'collection' ) ) ;
502
502
const docALocal = doc (
503
503
'collection/a' ,
@@ -544,64 +544,60 @@ describeSpec('Writes:', [], () => {
544
544
) ;
545
545
} ) ;
546
546
547
- specTest (
548
- 'Held writes are not re-sent after disable/enable network.' ,
549
- [ ] ,
550
- ( ) => {
551
- const query = Query . atPath ( path ( 'collection' ) ) ;
552
- const docALocal = doc (
553
- 'collection/a' ,
554
- 0 ,
555
- { v : 1 } ,
556
- { hasLocalMutations : true }
557
- ) ;
558
- const docA = doc ( 'collection/a' , 1000 , { v : 1 } ) ;
547
+ specTest ( 'Writes are not re-sent after disable/enable network.' , [ ] , ( ) => {
548
+ const query = Query . atPath ( path ( 'collection' ) ) ;
549
+ const docALocal = doc (
550
+ 'collection/a' ,
551
+ 0 ,
552
+ { v : 1 } ,
553
+ { hasLocalMutations : true }
554
+ ) ;
555
+ const docA = doc ( 'collection/a' , 1000 , { v : 1 } ) ;
559
556
560
- return (
561
- spec ( )
562
- . userListens ( query )
563
- . watchAcksFull ( query , 500 )
564
- . expectEvents ( query , { } )
565
- . userSets ( 'collection/a' , { v : 1 } )
566
- . expectEvents ( query , {
567
- hasPendingWrites : true ,
568
- added : [ docALocal ]
569
- } )
570
- // ack write but without a watch event.
571
- . writeAcks ( 'collection/a' , 1000 )
557
+ return (
558
+ spec ( )
559
+ . userListens ( query )
560
+ . watchAcksFull ( query , 500 )
561
+ . expectEvents ( query , { } )
562
+ . userSets ( 'collection/a' , { v : 1 } )
563
+ . expectEvents ( query , {
564
+ hasPendingWrites : true ,
565
+ added : [ docALocal ]
566
+ } )
567
+ // ack write but without a watch event.
568
+ . writeAcks ( 'collection/a' , 1000 )
572
569
573
- // handshake + write = 2 requests
574
- . expectWriteStreamRequestCount ( 2 )
570
+ // handshake + write = 2 requests
571
+ . expectWriteStreamRequestCount ( 2 )
575
572
576
- . disableNetwork ( )
577
- . expectEvents ( query , {
578
- hasPendingWrites : true ,
579
- fromCache : true
580
- } )
573
+ . disableNetwork ( )
574
+ . expectEvents ( query , {
575
+ hasPendingWrites : true ,
576
+ fromCache : true
577
+ } )
581
578
582
- // handshake + write + close = 3 requests
583
- . expectWriteStreamRequestCount ( 3 )
579
+ // handshake + write + close = 3 requests
580
+ . expectWriteStreamRequestCount ( 3 )
584
581
585
- . enableNetwork ( )
586
- . expectActiveTargets ( { query, resumeToken : 'resume-token-500' } )
582
+ . enableNetwork ( )
583
+ . expectActiveTargets ( { query, resumeToken : 'resume-token-500' } )
587
584
588
- // acked write should /not/ have been resent, so count should still be 3
589
- . expectWriteStreamRequestCount ( 3 )
585
+ // acked write should /not/ have been resent, so count should still be 3
586
+ . expectWriteStreamRequestCount ( 3 )
590
587
591
- // Finally watch catches up.
592
- . watchAcksFull ( query , 2000 , docA )
593
- . expectEvents ( query , {
594
- metadata : [ docA ]
595
- } )
596
- ) ;
597
- }
598
- ) ;
588
+ // Finally watch catches up.
589
+ . watchAcksFull ( query , 2000 , docA )
590
+ . expectEvents ( query , {
591
+ metadata : [ docA ]
592
+ } )
593
+ ) ;
594
+ } ) ;
599
595
600
596
specTest (
601
- 'Held writes are released when there are no queries left. ' ,
597
+ 'Writes are released when there are no queries left' ,
602
598
[ 'eager-gc' ] ,
603
- 'This test expects a new target id for a new listen, but without eager gc, the same target ' +
604
- 'id is reused ' ,
599
+ 'This test verifies that committed mutations are eligible for ' +
600
+ 'garbage collection on target removal ' ,
605
601
( ) => {
606
602
const query = Query . atPath ( path ( 'collection' ) ) ;
607
603
const docALocal = doc (
@@ -995,7 +991,7 @@ describeSpec('Writes:', [], () => {
995
991
}
996
992
) ;
997
993
998
- specTest ( 'Held write is released by primary client' , [ 'multi-client' ] , ( ) => {
994
+ specTest ( 'Writes are released by primary client' , [ 'multi-client' ] , ( ) => {
999
995
const query = Query . atPath ( path ( 'collection' ) ) ;
1000
996
const docALocal = doc (
1001
997
'collection/a' ,
0 commit comments