You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "nastra (via GitHub)" <gi...@apache.org> on 2024/06/15 14:42:22 UTC
Re: [PR] Remove all usages of deprecated AssertHelpers [iceberg]
nastra commented on code in PR #10500:
URL: https://github.com/apache/iceberg/pull/10500#discussion_r1641210236
##########
spark/v3.3/spark-extensions/src/test/java/org/apache/iceberg/spark/extensions/TestAddFilesProcedure.java:
##########
@@ -688,23 +688,23 @@ public void invalidDataImport() {
createIcebergTable("id Integer, name String, dept String, subdept String");
- AssertHelpers.assertThrows(
- "Should forbid adding of partitioned data to unpartitioned table",
- IllegalArgumentException.class,
- "Cannot use partition filter with an unpartitioned table",
- () ->
- scalarSql(
- "CALL %s.system.add_files('%s', '`parquet`.`%s`', map('id', 1))",
- catalogName, tableName, fileTableDir.getAbsolutePath()));
-
- AssertHelpers.assertThrows(
- "Should forbid adding of partitioned data to unpartitioned table",
- IllegalArgumentException.class,
- "Cannot add partitioned files to an unpartitioned table",
- () ->
- scalarSql(
- "CALL %s.system.add_files('%s', '`parquet`.`%s`')",
- catalogName, tableName, fileTableDir.getAbsolutePath()));
+ Assertions.assertThatThrownBy(
Review Comment:
it should be fine to statically import the method here, similar to how `assertThat` is already statically imported in this class.
--
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-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org