@@ -2820,15 +2820,15 @@ public function testRelationshipSpatialQueries(): void
28202820
28212821 // covers on relationship polygon attribute (point inside polygon)
28222822 $ restaurants = $ database ->find ('restaurantsSpatial ' , [
2823- Query::covers ('supplier.deliveryArea ' , [[-74.0 , 40.75 ]]),
2823+ Query::contains ('supplier.deliveryArea ' , [[-74.0 , 40.75 ]]),
28242824 ]);
28252825 $ this ->assertCount (1 , $ restaurants );
28262826 $ this ->assertEquals ('rest1 ' , $ restaurants [0 ]->getId ());
28272827
28282828 // covers on relationship linestring attribute
28292829 // Note: ST_Contains on linestrings is implementation-dependent (some DBs require exact point-on-line)
28302830 $ restaurants = $ database ->find ('restaurantsSpatial ' , [
2831- Query::covers ('supplier.deliveryRoute ' , [[-74.0060 , 40.7128 ]]),
2831+ Query::contains ('supplier.deliveryRoute ' , [[-74.0060 , 40.7128 ]]),
28322832 ]);
28332833 // Verify query executes (result count depends on DB spatial implementation)
28342834 $ this ->assertGreaterThanOrEqual (0 , count ($ restaurants ));
@@ -2900,7 +2900,7 @@ public function testRelationshipSpatialQueries(): void
29002900 // Multiple spatial queries combined
29012901 $ restaurants = $ database ->find ('restaurantsSpatial ' , [
29022902 Query::distanceLessThan ('supplier.warehouseLocation ' , [-74.0060 , 40.7128 ], 1.0 ),
2903- Query::covers ('supplier.deliveryArea ' , [[-74.0 , 40.75 ]]),
2903+ Query::contains ('supplier.deliveryArea ' , [[-74.0 , 40.75 ]]),
29042904 ]);
29052905 $ this ->assertCount (1 , $ restaurants );
29062906 $ this ->assertEquals ('rest1 ' , $ restaurants [0 ]->getId ());
0 commit comments