[test][is_valid] make is_valid test more elaborate by testing all
types of rings, polygons and multipolygons (open/closed, cw/ccw),
and by testing both then spikes/duplicates are allowed or not