> From: nimix [mailto:melchiorm...@gmail.com] > Sent: Friday, July 13, 2012 12:58 AM > To: dev@openstreetmap.org > Subject: [OSM-dev] (Multi)Polygon handling > > > Frederik Ramm wrote > > > > > > If we can't get everyone to use the same code base, then it would at > > least be great to reach some kind of agreement here, or maybe at least > > produce a test suite that everyone runs their code against. > > > > > > I created a testsuite for that with some more cases that need special > treatment. Unfortunately I only stored the WKB representation in Google > mercator projection, so it is not very human readable. The testcase > contains a LINESTRING and a MULTIPOLYGON for simple closed ways and for > relations a MULTILINESTRING and a MULTIPOLYGON ([1]). > > I would volunteer to bring it in an other format so that it is useful > for everyone writing converters and I would like to discuss what is the > best way to do it. I would suggest an .osm file and a Wiki Page > containing the expected results in WKT/WKB and some explanation for each > case. Any other ideas? > Best regards, > Melchior
My following of web standards has convinced me it is necessary to define the expected output in every case, including invalid ones, or you will have differing implementations. I've been giving it some thought as to what needs to be tested, and I don't think it's excessive. I'd estimate 25-50 small tests would cover everything. _______________________________________________ dev mailing list dev@openstreetmap.org http://lists.openstreetmap.org/listinfo/dev