PostGIS  2.5.0beta2dev-r@@SVN_REVISION@@

◆ test_grid_in_place()

static void test_grid_in_place ( void  )
static

Definition at line 160 of file liblwgeom/cunit/cu_misc.c.

References do_grid_test().

Referenced by misc_suite_setup().

161 {
162  do_grid_test(
163  "POINT ZM (5.1423999999 5.1423999999 5.1423999999 5.1423999999)",
164  "POINT(5.1424 5.1424 5.1424 5.1424)",
165  0.0001
166  );
167  do_grid_test(
168  "MULTIPOLYGON(((0 0,10 0,10 10,0 10,0 0)))",
169  "MULTIPOLYGON EMPTY",
170  20
171  );
172  do_grid_test(
173  "MULTIPOLYGON(((0 0,10 0,10 10,0 10,0 0)))",
174  "MULTIPOLYGON(((0 0,10 0,10 10, 0 10,0 0)))",
175  1
176  );
177  do_grid_test(
178  "LINESTRING(0 0,1 1, 2 2, 3 3, 4 4, 5 5)",
179  "LINESTRING(0 0,2 2,4 4)",
180  2
181  );
182  do_grid_test(
183  "MULTIPOINT(0 0,1 1, 2 2, 3 3, 4 4, 5 5)",
184  /* This preserves current behaviour, but is probably not right */
185  "MULTIPOINT(0 0,0 0,2 2,4 4,4 4,4 4)",
186  2
187  );
188  do_grid_test(
189  "MULTIPOLYGON(((0 0,10 0,10 10,0 10,0 0),(4 4, 4 5, 5 5, 5 4, 4 4)))",
190  "MULTIPOLYGON(((0 0,10 0,10 10, 0 10,0 0)))",
191  2
192  );
193  do_grid_test(
194  "MULTIPOLYGON(((0 0,10 0,10 10,0 10,0 0),(4 4, 4 5, 5 5, 5 4, 4 4)))",
195  "MULTIPOLYGON EMPTY",
196  20
197  );
198  do_grid_test(
199  "POINT Z (5 5 5)",
200  "POINT(0 0 0)",
201  20
202  );
203 }
static void do_grid_test(const char *wkt_in, const char *wkt_out, double size)
Here is the call graph for this function:
Here is the caller graph for this function: