[geos-commits] r2456 - in trunk/tests/xmltester: . tests/general
svn_geos at osgeo.org
svn_geos at osgeo.org
Sat May 2 05:44:32 EDT 2009
Author: strk
Date: 2009-05-02 05:44:32 -0400 (Sat, 02 May 2009)
New Revision: 2456
Added:
trunk/tests/xmltester/tests/general/MISSING
trunk/tests/xmltester/tests/general/TestRectanglePredicate.xml
Modified:
trunk/tests/xmltester/Makefile.am
Log:
Copy last portable JTS general test, add a file with info about what's missing
Modified: trunk/tests/xmltester/Makefile.am
===================================================================
--- trunk/tests/xmltester/Makefile.am 2009-05-02 09:42:20 UTC (rev 2455)
+++ trunk/tests/xmltester/Makefile.am 2009-05-02 09:44:32 UTC (rev 2456)
@@ -32,6 +32,7 @@
$(srcdir)/tests/general/TestFunctionPL.xml \
$(srcdir)/tests/general/TestFunctionPP.xml \
$(srcdir)/tests/general/TestInteriorPoint.xml \
+ $(srcdir)/tests/general/TestRectanglePredicate.xml \
$(srcdir)/tests/general/TestRelateAA.xml \
$(srcdir)/tests/general/TestRelateLA.xml \
$(srcdir)/tests/general/TestRelateLL.xml \
Added: trunk/tests/xmltester/tests/general/MISSING
===================================================================
--- trunk/tests/xmltester/tests/general/MISSING (rev 0)
+++ trunk/tests/xmltester/tests/general/MISSING 2009-05-02 09:44:32 UTC (rev 2456)
@@ -0,0 +1,17 @@
+Tests found in JTS/testxml/general and not ported as of rev 2455 (May 02 2009)
+----------------------------------------------------------------------------
+
+TestDensify.xml
+ - requires densify::Densifier still unported
+
+TestPreparedPointPredicate.xml
+ - requires using custom operation (PreparedGeometryOperation)
+
+TestPreparedPolygonPredicate.xml
+ - requires using custom operation (PreparedGeometryOperation)
+
+TestPreparedPredicatesWithGeometryCollection.xml
+ - requires using custom operation (PreparedGeometryOperation)
+
+TestUnaryUnion.xml
+ - requires geom::Geometry::Union() still unported
Added: trunk/tests/xmltester/tests/general/TestRectanglePredicate.xml
===================================================================
--- trunk/tests/xmltester/tests/general/TestRectanglePredicate.xml (rev 0)
+++ trunk/tests/xmltester/tests/general/TestRectanglePredicate.xml 2009-05-02 09:44:32 UTC (rev 2456)
@@ -0,0 +1,221 @@
+<run>
+ <precisionModel scale="1.0" offsetx="0.0" offsety="0.0"/>
+
+<case>
+ <desc>A disjoint</desc>
+ <a>
+ POLYGON(
+ (0 0, 80 0, 80 80, 0 80, 0 0))
+ </a>
+ <b>
+ POLYGON(
+ (100 200, 100 140, 180 140, 180 200, 100 200))
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+</case>
+
+<case>
+ <desc>A contained in rectangle</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ POLYGON((10 10, 10 90, 90 90, 90 10, 10 10))
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> true </op> </test>
+</case>
+
+<case>
+ <desc>A containing rectangle</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ POLYGON ((60 180, -100 120, -140 60, -40 20, -100 -80, 40 -20, 140 -100, 140 40, 260 160, 80 120, 60 180))
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+</case>
+
+<case>
+ <desc>mA containing rectangle</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ MULTIPOLYGON (((-60 180, -60 -60, 40 -20, 140 -100, 180 120, -20 140, -60 180)),
+ ((20 280, 0 180, 180 160, 200 280, 20 280)))
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="within" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="coveredBy" arg1="A" arg2="B"> true </op> </test>
+</case>
+
+<case>
+ <desc>L overlaps thru Y axis side</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ LINESTRING(10 10, 200 10)
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+</case>
+
+<case>
+ <desc>L overlaps thru X axis side</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ LINESTRING(10 10, 10 2000)
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> false </op> </test>
+</case>
+
+<case>
+ <desc>L line intersection</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ LINESTRING( 10 10, -10 -20 )
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> false </op> </test>
+</case>
+
+<case>
+ <desc>L in polygon boundary</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ LINESTRING( 10 0, 90 0 )
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>L (3 pts) in polygon boundary</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ LINESTRING( 10 0, 100 0, 100 50 )
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>L (4 pts) in polygon boundary</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ LINESTRING( 10 0, 100 0, 100 100, 50 100 )
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>mL with one component contained and one in boundary</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ MULTILINESTRING( (10 0, 20 0), (10 10, 20 20) )
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>mL with one component contained</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ MULTILINESTRING( (10 10, 10 20), (200 10, 200 20) )
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+</case>
+
+<case>
+ <desc>P in polygon boundary (Y axis)</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ POINT(100 50)
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>P in polygon boundary (X axis)</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ POINT(50 100)
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> false </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>P in polygon</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ POINT(60 60)
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+<case>
+ <desc>mP in polygon boundary and interior</desc>
+ <a>
+ POLYGON((0 0, 100 0, 100 100, 0 100, 0 0))
+ </a>
+ <b>
+ MULTIPOINT((50 100), (60 60))
+ </b>
+<test> <op name="intersects" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="contains" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="covers" arg1="A" arg2="B"> true </op> </test>
+<test> <op name="coveredBy" arg1="B" arg2="A"> true </op> </test>
+</case>
+
+
+
+
+</run>
More information about the geos-commits
mailing list