nastra commented on code in PR #9670: URL: https://github.com/apache/iceberg/pull/9670#discussion_r1487317862
########## spark/v3.5/spark-extensions/src/test/java/org/apache/iceberg/spark/extensions/TestDelete.java: ########## @@ -1296,40 +1282,36 @@ public void testDeleteToWapBranch() throws NoSuchTableException { ImmutableMap.of(SparkSQLProperties.WAP_BRANCH, "wap"), () -> { sql("DELETE FROM %s t WHERE id=0", tableName); - Assert.assertEquals( - "Should have expected num of rows when reading table", - 2L, - spark.table(tableName).count()); - Assert.assertEquals( - "Should have expected num of rows when reading WAP branch", - 2L, - spark.table(tableName + ".branch_wap").count()); - Assert.assertEquals( - "Should not modify main branch", 3L, spark.table(tableName + ".branch_main").count()); + assertThat(spark.table(tableName).count()) + .as("Should have expected num of rows when reading table") + .isEqualTo(2L); + assertThat(spark.table(tableName + ".branch_wap").count()) + .as("Should have expected num of rows when reading WAP branch") + .isEqualTo(2L); + assertThat(spark.table(tableName + ".branch_main").count()) + .as("Should not modify main branch") + .isEqualTo(3L); }); withSQLConf( ImmutableMap.of(SparkSQLProperties.WAP_BRANCH, "wap"), () -> { sql("DELETE FROM %s t WHERE id=1", tableName); - Assert.assertEquals( - "Should have expected num of rows when reading table with multiple writes", - 1L, - spark.table(tableName).count()); - Assert.assertEquals( - "Should have expected num of rows when reading WAP branch with multiple writes", - 1L, - spark.table(tableName + ".branch_wap").count()); - Assert.assertEquals( - "Should not modify main branch with multiple writes", - 3L, - spark.table(tableName + ".branch_main").count()); + assertThat(spark.table(tableName).count()) + .as("Should have expected num of rows when reading table with multiple writes") + .isEqualTo(1L); + assertThat(spark.table(tableName + ".branch_wap").count()) + .as("Should have expected num of rows when reading WAP branch with multiple writes") + .isEqualTo(1L); + assertThat(spark.table(tableName + ".branch_main").count()) + .as("Should not modify main branch with multiple writes") + .isEqualTo(3L); }); } - @Test + @TestTemplate public void testDeleteToWapBranchWithTableBranchIdentifier() throws NoSuchTableException { - Assume.assumeTrue("Test must have branch name part in table identifier", branch != null); + assumeThat(branch != null).as("Test must have branch name part in table identifier").isTrue(); Review Comment: please use `.isNotNull()` -- 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