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


##########
flink/v1.15/flink/src/test/java/org/apache/iceberg/flink/sink/TestFlinkIcebergSinkV2.java:
##########
@@ -201,19 +201,19 @@ public void testUpsertModeCheck() throws Exception {
             .tableSchema(SimpleDataUtil.FLINK_SCHEMA)
             .writeParallelism(parallelism)
             .upsert(true);
-
-    AssertHelpers.assertThrows(
-        "Should be error because upsert mode and overwrite mode enable at the 
same time.",
-        IllegalStateException.class,
-        "OVERWRITE mode shouldn't be enable",
-        () ->
-            builder.equalityFieldColumns(ImmutableList.of("id", 
"data")).overwrite(true).append());
-
-    AssertHelpers.assertThrows(
-        "Should be error because equality field columns are empty.",
-        IllegalStateException.class,
-        "Equality field columns shouldn't be empty",
-        () -> 
builder.equalityFieldColumns(ImmutableList.of()).overwrite(false).append());
+    Assertions.assertThatThrownBy(

Review Comment:
   please align this with how it's done for Flink 1.17, where it uses 
`.hasMessage("OVERWRITE mode shouldn't be enable when configuring to use UPSERT 
data stream.")`
   
   same for all the other places



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to