iGN5117 commented on code in PR #867:
URL: https://github.com/apache/sedona/pull/867#discussion_r1238838501


##########
common/src/test/java/org/apache/sedona/common/FunctionsTest.java:
##########
@@ -268,6 +268,38 @@ public void splitHeterogeneousGeometryCollection() {
         assertNull(actualResult);
     }
 

Review Comment:
   Please separate different testCases to different tests since these are unit 
tests.
   
   You can have tests like dimensionGeom2D, dimensionGeomCollection, 
dimensionGeomEmpty, etc.
   
   Also, use assertEquals(expected, actual) format so that the test failure 
flags expected and actual properly.
   
   Additionally, please add test cases testing 3D geometry as well



##########
sql/common/src/test/scala/org/apache/sedona/sql/functionTestScala.scala:
##########
@@ -137,6 +137,20 @@ class functionTestScala extends TestBaseScala with 
Matchers with GeometrySample
       assert(functionDf.count() > 0);
     }
 

Review Comment:
   You can follow the map way of specifying multiple test cases and their 
expected output here, it is more readable



##########
docs/api/sql/Function.md:
##########
@@ -400,6 +400,28 @@ Result:
 POLYGON ((0 -3, -3 -3, -3 3, 0 3, 0 -3))
 ```
 
+## ST_Dimension
+
+Introduction: Return the topological dimension of this Geometry object, which 
must be less than or equal to the coordinate dimension. OGC SPEC s2.1.1.1 - 
returns 0 for POINT, 1 for LINESTRING, 2 for POLYGON, and the largest dimension 
of the components of a GEOMETRYCOLLECTION. If the dimension is unknown (e.g. 
for an empty GEOMETRYCOLLECTION) 0 is returned.
+
+Format: `ST_Dimension (A:geometry), ST_Dimension (C:geometrycolletion), `

Review Comment:
   type in collection here



##########
docs/api/flink/Function.md:
##########
@@ -262,6 +262,27 @@ Input: `Polygon ((0 0, 1 2, 2 2, 3 2, 5 0, 4 0, 3 1, 2 1, 
1 0, 0 0))`
 
 Output: `POLYGON ((1 2, 2 2, 3 2, 5 0, 4 0, 1 0, 0 0, 1 2))`
 
+## ST_Dimension
+
+Introduction: Return the topological dimension of this Geometry object, which 
must be less than or equal to the coordinate dimension. OGC SPEC s2.1.1.1 - 
returns 0 for POINT, 1 for LINESTRING, 2 for POLYGON, and the largest dimension 
of the components of a GEOMETRYCOLLECTION. If the dimension is unknown (e.g. 
for an empty GEOMETRYCOLLECTION) 0 is returned.
+
+Format: `ST_Dimension (A:geometry), ST_Dimension (C:geometrycolletion), `

Review Comment:
   typo in collection here



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to