rdblue commented on code in PR #11831:
URL: https://github.com/apache/iceberg/pull/11831#discussion_r1927926035


##########
api/src/test/java/org/apache/iceberg/types/TestTypeUtil.java:
##########
@@ -24,38 +24,43 @@
 import static org.assertj.core.api.Assertions.assertThatThrownBy;
 
 import java.util.Set;
+import java.util.stream.Stream;
 import org.apache.iceberg.Schema;
 import org.apache.iceberg.relocated.com.google.common.collect.Lists;
 import org.apache.iceberg.relocated.com.google.common.collect.Sets;
-import org.apache.iceberg.types.Types.IntegerType;
 import org.junit.jupiter.api.Test;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.Arguments;
+import org.junit.jupiter.params.provider.MethodSource;
 
 public class TestTypeUtil {
-  @Test
-  public void testReassignIdsDuplicateColumns() {
+  private static Stream<Arguments> testTypes() {
+    return Stream.of(Arguments.of(Types.IntegerType.get()), 
Arguments.of(Types.VariantType.get()));
+  }
+
+  @ParameterizedTest
+  @MethodSource("testTypes")
+  public void testReassignIdsDuplicateColumns(Type testType) {
     Schema schema =
-        new Schema(
-            required(0, "a", Types.IntegerType.get()), required(1, "A", 
Types.IntegerType.get()));
+        new Schema(required(0, "a", testType), required(1, "A", 
Types.IntegerType.get()));
     Schema sourceSchema =
-        new Schema(
-            required(1, "a", Types.IntegerType.get()), required(2, "A", 
Types.IntegerType.get()));
+        new Schema(required(1, "a", testType), required(2, "A", 
Types.IntegerType.get()));
     final Schema actualSchema = TypeUtil.reassignIds(schema, sourceSchema);
     assertThat(actualSchema.asStruct()).isEqualTo(sourceSchema.asStruct());
   }
 
-  @Test
-  public void testReassignIdsWithIdentifier() {
+  @ParameterizedTest
+  @MethodSource("testTypes")
+  public void testReassignIdsWithIdentifier(Type testType) {

Review Comment:
   Please roll back changes to this test.



##########
api/src/test/java/org/apache/iceberg/types/TestTypeUtil.java:
##########
@@ -64,19 +69,18 @@ public void testReassignIdsWithIdentifier() {
         .isEqualTo(sourceSchema.identifierFieldIds());
   }
 
-  @Test
-  public void testAssignIncreasingFreshIdWithIdentifier() {
+  @ParameterizedTest
+  @MethodSource("testTypes")
+  public void testAssignIncreasingFreshIdWithIdentifier(Type testType) {

Review Comment:
   Please roll back changes to this test.



-- 
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