PostGIS  3.4.0dev-r@@SVN_REVISION@@

◆ test_wkt_in_errlocation()

static void test_wkt_in_errlocation ( void  )
static

Definition at line 351 of file cu_in_wkt.c.

352 {
354  int rv = 0;
355  char *wkt = 0;
356 
357  wkt = "LINESTRING((0 0 0,1 1)";
359  rv = lwgeom_parse_wkt(&p, wkt, LW_PARSER_CHECK_ALL);
360  CU_ASSERT_EQUAL( rv, LW_FAILURE );
361  CU_ASSERT((12 - p.errlocation) < 1.5);
362 
363 // printf("errlocation %d\n", p.errlocation);
364 // printf("message %s\n", p.message);
365 
367 
368 }
#define LW_PARSER_CHECK_ALL
Definition: liblwgeom.h:2115
#define LW_FAILURE
Definition: liblwgeom.h:96
void lwgeom_parser_result_init(LWGEOM_PARSER_RESULT *parser_result)
Definition: lwin_wkt.c:880
int lwgeom_parse_wkt(LWGEOM_PARSER_RESULT *parser_result, char *wktstr, int parse_flags)
Parse a WKT geometry string into an LWGEOM structure.
void lwgeom_parser_result_free(LWGEOM_PARSER_RESULT *parser_result)
Definition: lwin_wkt.c:886
Parser result structure: returns the result of attempting to convert (E)WKT/(E)WKB to LWGEOM.
Definition: liblwgeom.h:2122

References struct_lwgeom_parser_result::errlocation, LW_FAILURE, LW_PARSER_CHECK_ALL, lwgeom_parse_wkt(), lwgeom_parser_result_free(), and lwgeom_parser_result_init().

Referenced by wkt_in_suite_setup().

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