nastra commented on code in PR #12148:
URL: https://github.com/apache/iceberg/pull/12148#discussion_r1938256698


##########
spark/v3.4/spark/src/test/java/org/apache/iceberg/spark/actions/TestSparkFileRewriter.java:
##########
@@ -304,6 +307,17 @@ public void testInvalidValuesForBinPackDataOptions() {
         ImmutableMap.of(SizeBasedDataRewriter.DELETE_FILE_THRESHOLD, "-1");
     assertThatThrownBy(() -> rewriter.init(invalidDeleteThresholdOptions))
         .hasMessageContaining("'delete-file-threshold' is set to -1 but must 
be >= 0");
+
+    Map<String, String> negativeDeleteRatioThresholdOptions =
+        ImmutableMap.of(SizeBasedDataRewriter.DELETE_RATIO_THRESHOLD, "-1");
+    assertThatThrownBy(() -> 
rewriter.init(negativeDeleteRatioThresholdOptions))
+        .hasMessageContaining("'delete-ratio-threshold' is set to negative but 
must be >= 0");
+
+    Map<String, String> invalidDeleteRatioThresholdOptions =
+        ImmutableMap.of(SizeBasedDataRewriter.DELETE_RATIO_THRESHOLD, "127");
+    ;

Review Comment:
   ```suggestion
   
   ```



##########
spark/v3.4/spark/src/test/java/org/apache/iceberg/spark/actions/TestSparkFileRewriter.java:
##########
@@ -322,6 +336,17 @@ public void testInvalidValuesForSortDataOptions() {
         ImmutableMap.of(SparkShufflingDataRewriter.COMPRESSION_FACTOR, "0");
     assertThatThrownBy(() -> rewriter.init(invalidCompressionFactorOptions))
         .hasMessageContaining("'compression-factor' is set to 0.0 but must be 
> 0");
+
+    Map<String, String> negativeDeleteRatioThresholdOptions =
+        ImmutableMap.of(SparkShufflingDataRewriter.DELETE_RATIO_THRESHOLD, 
"-1");
+    assertThatThrownBy(() -> 
rewriter.init(negativeDeleteRatioThresholdOptions))
+        .hasMessageContaining("'delete-ratio-threshold' is set to negative but 
must be >= 0");
+
+    Map<String, String> invalidDeleteRatioThresholdOptions =
+        ImmutableMap.of(SparkShufflingDataRewriter.DELETE_RATIO_THRESHOLD, 
"127");
+    ;

Review Comment:
   same as above



-- 
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: issues-unsubscr...@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to