@@ -769,9 +769,12 @@ public void testCreateNotificationCreateTableInExternalLocation() {
769769 // The location of the metadata JSON file specified is outside of the table's base location
770770 // according to the
771771 // metadata. We assume this is fraudulent and disallowed
772- final String tableLocation = "s3://my-bucket/path/to/data/my_table/" ;
772+ final String tableSuffix = UUID .randomUUID ().toString ();
773+ final String tableLocation =
774+ String .format ("s3://my-bucket/path/to/data/my_table_%s/" , tableSuffix );
773775 final String tableMetadataLocation = tableLocation + "metadata/v1.metadata.json" ;
774- final String anotherTableLocation = "s3://my-bucket/path/to/data/another_table/" ;
776+ final String anotherTableLocation =
777+ String .format ("s3://my-bucket/path/to/data/another_table_%s/" , tableSuffix );
775778
776779 metaStoreManager .updateEntityPropertiesIfNotChanged (
777780 polarisContext ,
@@ -820,15 +823,18 @@ public void testCreateNotificationCreateTableOutsideOfMetadataLocation() {
820823 Assumptions .assumeTrue (
821824 supportsNotifications (), "Only applicable if notifications are supported" );
822825
826+ final String tableSuffix = UUID .randomUUID ().toString ();
823827 // The location of the metadata JSON file specified is outside of the table's metadata directory
824828 // according to the
825829 // metadata. We assume this is fraudulent and disallowed
826- final String tableLocation = "s3://my-bucket/path/to/data/my_table/" ;
830+ final String tableLocation =
831+ String .format ("s3://my-bucket/path/to/data/my_table_%s/" , tableSuffix );
827832 final String tableMetadataLocation = tableLocation + "metadata/v3.metadata.json" ;
828833
829834 // this passes the first validation, since it's within the namespace subdirectory, but
830835 // the location is in another table's subdirectory
831- final String anotherTableLocation = "s3://my-bucket/path/to/data/another_table" ;
836+ final String anotherTableLocation =
837+ String .format ("s3://my-bucket/path/to/data/another_table_%s" , tableSuffix );
832838
833839 metaStoreManager .updateEntityPropertiesIfNotChanged (
834840 polarisContext ,
@@ -880,9 +886,12 @@ public void testUpdateNotificationCreateTableInExternalLocation() {
880886 // The location of the metadata JSON file specified is outside of the table's base location
881887 // according to the
882888 // metadata. We assume this is fraudulent and disallowed
883- final String tableLocation = "s3://my-bucket/path/to/data/my_table/" ;
889+ final String tableSuffix = UUID .randomUUID ().toString ();
890+ final String tableLocation =
891+ String .format ("s3://my-bucket/path/to/data/my_table_%s/" , tableSuffix );
884892 final String tableMetadataLocation = tableLocation + "metadata/v1.metadata.json" ;
885- final String anotherTableLocation = "s3://my-bucket/path/to/data/another_table/" ;
893+ final String anotherTableLocation =
894+ String .format ("s3://my-bucket/path/to/data/another_table_%s/" , tableSuffix );
886895
887896 metaStoreManager .updateEntityPropertiesIfNotChanged (
888897 polarisContext ,
0 commit comments