dimas-b commented on code in PR #4034:
URL: https://github.com/apache/polaris/pull/4034#discussion_r2968432571


##########
runtime/service/src/intTest/java/org/apache/polaris/service/it/RestCatalogMinIOSpecialIT.java:
##########
@@ -265,8 +301,89 @@ public void testCreateTableVendedCredentials(boolean 
pathStyle) throws IOExcepti
     assertThat(response.credentials()).hasSize(1);
   }
 
+  @ParameterizedTest
+  @CsvSource({
+    "false, false, false",
+    "true,  false, false",
+    "false, true,  false",
+    "true,  true,  true",
+  })
+  public void 
testCreateTableVendedCredentialsWithAwsShapeTriggersMinioKmsFailure(
+      boolean includeRegion, boolean includeRoleArn, boolean expectFailure) 
throws IOException {
+    try (RESTCatalog restCatalog =
+        createCatalog(
+            Optional.of(endpoint),
+            Optional.of(endpoint),
+            true,
+            Optional.empty(),
+            Optional.of(VENDED_CREDENTIALS),
+            true,
+            includeRegion ? Optional.of(TEST_REGION) : Optional.empty(),
+            includeRoleArn ? Optional.of(TEST_ROLE_ARN) : Optional.empty(),
+            Optional.of(false))) {
+      TableIdentifier id = createTableAndVerifyMetadata(restCatalog);
+      if (expectFailure) {

Review Comment:
   Would you mind refactoring expected failures and successes into two separate 
test methods? I believe it would be easier for the reader to follow the test 
logic and analyse failures, should they occur.



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

Reply via email to