PostGIS  2.2.8dev-r@@SVN_REVISION@@

◆ test_wkt_in_polygon()

static void test_wkt_in_polygon ( void  )
static

Definition at line 138 of file cu_in_wkt.c.

References cu_wkt_in(), lwfree(), r, s, and WKT_SFSQL.

Referenced by wkt_in_suite_setup().

139 {
140  s = "POLYGON((0 0,0 1,1 1,0 0))";
141  r = cu_wkt_in(s, WKT_SFSQL);
142  CU_ASSERT_STRING_EQUAL(r,s);
143  lwfree(r);
144 
145  s = "POLYGON Z ((0 0,0 10,10 10,10 0,0 0),(1 1 1,1 2 1,2 2 1,2 1 1,1 1 1))";
146  r = cu_wkt_in(s, WKT_SFSQL);
147  CU_ASSERT_STRING_EQUAL(r,"can not mix dimensionality in a geometry");
148  lwfree(r);
149 
150  s = "POLYGON Z ((0 0,0 10,10 10,10 0,0 0),(1 1,1 2,2 2,2 1,1 1))";
151  r = cu_wkt_in(s, WKT_SFSQL);
152  CU_ASSERT_STRING_EQUAL(r,"can not mix dimensionality in a geometry");
153  //printf("\nIN: %s\nOUT: %s\n",s,r);
154  lwfree(r);
155 }
char * r
Definition: cu_in_wkt.c:24
void lwfree(void *mem)
Definition: lwutil.c:214
char * s
Definition: cu_in_wkt.c:23
#define WKT_SFSQL
Definition: liblwgeom.h:1940
static char * cu_wkt_in(char *wkt, uint8_t variant)
Definition: cu_in_wkt.c:50
Here is the call graph for this function:
Here is the caller graph for this function: