PostGIS  2.4.9dev-r@@SVN_REVISION@@

◆ test_twkb_out_linestring()

static void test_twkb_out_linestring ( void  )
static

Definition at line 131 of file cu_out_twkb.c.

References cu_twkb(), s, and TWKB_BBOX.

Referenced by twkb_out_suite_setup().

132 {
133 
134  cu_twkb("LINESTRING(0 0,1 1)", 0, 0, 0, 0);
135  CU_ASSERT_STRING_EQUAL(s,"02000200000202");
136  // printf("TWKB: %s\n",s);
137 
138  cu_twkb("LINESTRING(0 0 1,1 1 2,2 2 3)", 0, 0, 0, 0);
139  CU_ASSERT_STRING_EQUAL(s,"02080103000002020202020202");
140  // printf("TWKB: %s\n",s);
141 
142  /* Line with bounding box */
143  cu_twkb("LINESTRING(0 0,1 1,2 2)", 0, 0, 0, TWKB_BBOX);
144  CU_ASSERT_STRING_EQUAL(s,"02010004000403000002020202");
145  // printf("TWKB: %s\n",s);
146 
147  cu_twkb("LINESTRING EMPTY", 0, 0, 0, 0);
148  CU_ASSERT_STRING_EQUAL(s,"0210");
149  // printf("TWKB: %s\n",s);
150 }
char * s
Definition: cu_out_twkb.c:24
static void cu_twkb(char *wkt, int8_t prec_xy, int8_t prec_z, int8_t prec_m, uint8_t variant)
Definition: cu_out_twkb.c:55
#define TWKB_BBOX
Definition: liblwgeom.h:2091
Here is the call graph for this function:
Here is the caller graph for this function: