@@ -398,6 +398,10 @@ public function testInitialCursorIsNotClosed()
398
398
399
399
public function testNextResumeTokenNotFound ()
400
400
{
401
+ if (version_compare ($ this ->getServerVersion (), '4.1.8 ' , '>= ' )) {
402
+ $ this ->markTestSkipped ('Server rejects change streams that modify resume token (SERVER-37786) ' );
403
+ }
404
+
401
405
$ pipeline = [['$project ' => ['_id ' => 0 ]]];
402
406
403
407
$ operation = new Watch ($ this ->manager , $ this ->getDatabaseName (), $ this ->getCollectionName (), $ pipeline , $ this ->defaultOptions );
@@ -414,6 +418,10 @@ public function testNextResumeTokenNotFound()
414
418
415
419
public function testRewindResumeTokenNotFound ()
416
420
{
421
+ if (version_compare ($ this ->getServerVersion (), '4.1.8 ' , '>= ' )) {
422
+ $ this ->markTestSkipped ('Server rejects change streams that modify resume token (SERVER-37786) ' );
423
+ }
424
+
417
425
$ pipeline = [['$project ' => ['_id ' => 0 ]]];
418
426
419
427
$ operation = new Watch ($ this ->manager , $ this ->getDatabaseName (), $ this ->getCollectionName (), $ pipeline , $ this ->defaultOptions );
@@ -428,6 +436,10 @@ public function testRewindResumeTokenNotFound()
428
436
429
437
public function testNextResumeTokenInvalidType ()
430
438
{
439
+ if (version_compare ($ this ->getServerVersion (), '4.1.8 ' , '>= ' )) {
440
+ $ this ->markTestSkipped ('Server rejects change streams that modify resume token (SERVER-37786) ' );
441
+ }
442
+
431
443
$ pipeline = [['$project ' => ['_id ' => ['$literal ' => 'foo ' ]]]];
432
444
433
445
$ operation = new Watch ($ this ->manager , $ this ->getDatabaseName (), $ this ->getCollectionName (), $ pipeline , $ this ->defaultOptions );
@@ -444,6 +456,10 @@ public function testNextResumeTokenInvalidType()
444
456
445
457
public function testRewindResumeTokenInvalidType ()
446
458
{
459
+ if (version_compare ($ this ->getServerVersion (), '4.1.8 ' , '>= ' )) {
460
+ $ this ->markTestSkipped ('Server rejects change streams that modify resume token (SERVER-37786) ' );
461
+ }
462
+
447
463
$ pipeline = [['$project ' => ['_id ' => ['$literal ' => 'foo ' ]]]];
448
464
449
465
$ operation = new Watch ($ this ->manager , $ this ->getDatabaseName (), $ this ->getCollectionName (), $ pipeline , $ this ->defaultOptions );
@@ -628,6 +644,10 @@ public function testNextAdvancesKey()
628
644
629
645
public function testResumeTokenNotFoundAdvancesKey ()
630
646
{
647
+ if (version_compare ($ this ->getServerVersion (), '4.1.8 ' , '>= ' )) {
648
+ $ this ->markTestSkipped ('Server rejects change streams that modify resume token (SERVER-37786) ' );
649
+ }
650
+
631
651
$ pipeline = [['$project ' => ['_id ' => 0 ]]];
632
652
633
653
$ operation = new Watch ($ this ->manager , $ this ->getDatabaseName (), $ this ->getCollectionName (), $ pipeline , $ this ->defaultOptions );
0 commit comments