PostGIS 3.7.0dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ ASSERT_LWGEOM_EQUAL

#define ASSERT_LWGEOM_EQUAL (   o,
 
)
Value:
do { \
if ( !lwgeom_same(o, e) ) { \
char* wkt_o = lwgeom_to_ewkt(o); \
char* wkt_e = lwgeom_to_ewkt(e); \
fprintf(stderr, "[%s:%d]\n Expected: %s\n Obtained: %s\n", __FILE__, __LINE__, (wkt_o), (wkt_e)); \
lwfree(wkt_o); \
lwfree(wkt_e); \
} \
CU_ASSERT_TRUE(lwgeom_same(o, e)); \
} while(0);
char lwgeom_same(const LWGEOM *lwgeom1, const LWGEOM *lwgeom2)
geom1 same as geom2 iff
Definition lwgeom.c:619
char * lwgeom_to_ewkt(const LWGEOM *lwgeom)
Return an allocated string.
Definition lwgeom.c:593

Definition at line 109 of file liblwgeom/cunit/cu_tester.h.

109 { \
110 if ( !lwgeom_same(o, e) ) { \
111 char* wkt_o = lwgeom_to_ewkt(o); \
112 char* wkt_e = lwgeom_to_ewkt(e); \
113 fprintf(stderr, "[%s:%d]\n Expected: %s\n Obtained: %s\n", __FILE__, __LINE__, (wkt_o), (wkt_e)); \
114 lwfree(wkt_o); \
115 lwfree(wkt_e); \
116 } \
117 CU_ASSERT_TRUE(lwgeom_same(o, e)); \
118} while(0);