Skip to content

Commit

Permalink
Add test of prepared geometry against mixed collections
Browse files Browse the repository at this point in the history
  • Loading branch information
pramsey committed Oct 31, 2023
1 parent d7a5a51 commit a7a12f5
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions tests/unit/geom/prep/PreparedGeometryTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,21 @@ void object::test<1>
ensure( pg1->covers(g2.get()));
}


// See https://trac.osgeo.org/postgis/ticket/5601
template<>
template<>
void object::test<2>
()
{
g1 = reader.read( "LINESTRING(-1 0,0 0)" );
g2 = reader.read( "GEOMETRYCOLLECTION(MULTIPOINT(-1 0),LINESTRING(0 -1,1 0))" );

pg1 = prep::PreparedGeometryFactory::prepare(g1.get());

ensure( g1->intersects(g2.get()) );
ensure( pg1->intersects(g2.get()) );
}


} // namespace tut

0 comments on commit a7a12f5

Please sign in to comment.