PostGIS  2.5.0dev-r@@SVN_REVISION@@
static void test_wkt_in_linestring ( void  )
static

Definition at line 93 of file cu_in_wkt.c.

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

Referenced by wkt_in_suite_setup().

94 {
95  s = "LINESTRING EMPTY";
96  r = cu_wkt_in(s, WKT_SFSQL);
97  CU_ASSERT_STRING_EQUAL(r,s);
98  lwfree(r);
99 
100  s = "LINESTRING(0 0,1 1)";
101  r = cu_wkt_in(s, WKT_SFSQL);
102  CU_ASSERT_STRING_EQUAL(r,s);
103  lwfree(r);
104 
105  s = "LINESTRING(0 0 0,1 1 1)";
107  CU_ASSERT_STRING_EQUAL(r,s);
108  lwfree(r);
109 
110  s = "LINESTRING M (0 0 0,1 1 1)";
111  r = cu_wkt_in(s, WKT_ISO);
112  CU_ASSERT_STRING_EQUAL(r,s);
113  lwfree(r);
114 
115  s = "LINESTRING ZM (0 0 0 1,1 1 1 1,2 2 2 2,0.141231 4 5 4)";
116  r = cu_wkt_in(s, WKT_ISO);
117  CU_ASSERT_STRING_EQUAL(r,s);
118  lwfree(r);
119 
120  s = "LINESTRINGM(0 0 0,1 1 1)";
122  CU_ASSERT_STRING_EQUAL(r,s);
123  lwfree(r);
124 
125  s = "LINESTRING ZM EMPTY";
126  r = cu_wkt_in(s, WKT_ISO);
127  CU_ASSERT_STRING_EQUAL(r,s);
128  lwfree(r);
129 
130  s = "LINESTRING Z (0 0 0 1, 0 1 0 1)";
132  CU_ASSERT_STRING_EQUAL(r,"can not mix dimensionality in a geometry");
133  //printf("\nIN: %s\nOUT: %s\n",s,r);
134  lwfree(r);
135 
136 }
char * r
Definition: cu_in_wkt.c:24
void lwfree(void *mem)
Definition: lwutil.c:244
#define WKT_ISO
Definition: liblwgeom.h:2068
char * s
Definition: cu_in_wkt.c:23
#define WKT_EXTENDED
Definition: liblwgeom.h:2070
#define WKT_SFSQL
Definition: liblwgeom.h:2069
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: