66use MongoDB \Collection ;
77use MongoDB \Database ;
88use MongoDB \Driver \BulkWrite ;
9- use MongoDB \Driver \Cursor ;
9+ use MongoDB \Driver \CursorInterface ;
1010use MongoDB \Driver \ReadConcern ;
1111use MongoDB \Driver \ReadPreference ;
1212use MongoDB \Driver \WriteConcern ;
@@ -79,7 +79,7 @@ public function testCommand(): void
7979
8080 $ cursor = $ this ->database ->command ($ command , $ options );
8181
82- $ this ->assertInstanceOf (Cursor ::class, $ cursor );
82+ $ this ->assertInstanceOf (CursorInterface ::class, $ cursor );
8383 $ commandResult = current ($ cursor ->toArray ());
8484
8585 $ this ->assertCommandSucceeded ($ commandResult );
@@ -99,7 +99,7 @@ public function testCommandDoesNotInheritReadPreference(): void
9999
100100 $ cursor = $ this ->database ->command ($ command );
101101
102- $ this ->assertInstanceOf (Cursor ::class, $ cursor );
102+ $ this ->assertInstanceOf (CursorInterface ::class, $ cursor );
103103 $ this ->assertTrue ($ cursor ->getServer ()->isPrimary ());
104104 }
105105
@@ -113,7 +113,7 @@ public function testCommandAppliesTypeMapToCursor(): void
113113
114114 $ cursor = $ this ->database ->command ($ command , $ options );
115115
116- $ this ->assertInstanceOf (Cursor ::class, $ cursor );
116+ $ this ->assertInstanceOf (CursorInterface ::class, $ cursor );
117117 $ commandResult = current ($ cursor ->toArray ());
118118
119119 $ this ->assertCommandSucceeded ($ commandResult );
0 commit comments