PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ test_coll_coll()

static void test_coll_coll ( void  )
static

Definition at line 105 of file cu_homogenize.c.

106 {
107  /* Two different types together must produce a Collection as output */
108  do_geom_test("GEOMETRYCOLLECTION(POINT(1 2),LINESTRING(3 4,5 6))",
109  "GEOMETRYCOLLECTION(POINT(1 2),LINESTRING(3 4,5 6))");
110 
111  do_geom_test("GEOMETRYCOLLECTION(LINESTRING(1 2,3 4),POLYGON((5 6,7 8,9 10,5 6)))",
112  "GEOMETRYCOLLECTION(LINESTRING(1 2,3 4),POLYGON((5 6,7 8,9 10,5 6)))");
113 
114 
115  /* Ability to produce a single MULTI with same type */
116  do_geom_test("GEOMETRYCOLLECTION(POINT(1 2),LINESTRING(3 4,5 6),POINT(7 8))",
117  "GEOMETRYCOLLECTION(MULTIPOINT(1 2,7 8),LINESTRING(3 4,5 6))");
118 
119  do_geom_test("GEOMETRYCOLLECTION(POINT(1 2),LINESTRING(3 4,5 6),MULTIPOINT(7 8,9 10))",
120  "GEOMETRYCOLLECTION(MULTIPOINT(1 2,7 8,9 10),LINESTRING(3 4,5 6))");
121 
122 
123  /* Recursive Collection handle */
124  do_geom_test("GEOMETRYCOLLECTION(GEOMETRYCOLLECTION(GEOMETRYCOLLECTION(POINT(1 2))))",
125  "POINT(1 2)");
126 
127  do_geom_test("GEOMETRYCOLLECTION(POINT(1 2),GEOMETRYCOLLECTION(LINESTRING(3 4,5 6)))",
128  "GEOMETRYCOLLECTION(POINT(1 2),LINESTRING(3 4,5 6))");
129 
130 
131  /* EMPTY Collection */
132  do_geom_test("GEOMETRYCOLLECTION EMPTY",
133  "GEOMETRYCOLLECTION EMPTY");
134 
135 
136  /* Recursive EMPTY Collection */
137  do_geom_test("GEOMETRYCOLLECTION(GEOMETRYCOLLECTION EMPTY)",
138  "GEOMETRYCOLLECTION EMPTY");
139 
140  do_geom_test("GEOMETRYCOLLECTION(GEOMETRYCOLLECTION(GEOMETRYCOLLECTION EMPTY))",
141  "GEOMETRYCOLLECTION EMPTY");
142 }
static void do_geom_test(char *in, char *out)
Definition: cu_homogenize.c:20

References do_geom_test().

Referenced by homogenize_suite_setup().

Here is the call graph for this function:
Here is the caller graph for this function: