This is an automated email from the ASF dual-hosted git repository.

morrysnow pushed a commit to branch branch-3.1
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-3.1 by this push:
     new e2952fe24f4 branch-3.1: [fix](test)Validate database is empty before 
DROP DATABASE #58344 (#58422)
e2952fe24f4 is described below

commit e2952fe24f41c22010a6556288db9df27e0d9706
Author: Calvin Kirs <[email protected]>
AuthorDate: Thu Nov 27 10:27:45 2025 +0800

    branch-3.1: [fix](test)Validate database is empty before DROP DATABASE 
#58344 (#58422)
    
    bp #58344
---
 .../refactor_catalog_param/azure_blob_all_test.groovy               | 5 +++--
 .../iceberg_on_hms_and_filesystem_and_dlf.groovy                    | 6 +++++-
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git 
a/regression-test/suites/external_table_p2/refactor_catalog_param/azure_blob_all_test.groovy
 
b/regression-test/suites/external_table_p2/refactor_catalog_param/azure_blob_all_test.groovy
index 03ef1c576ac..7451e6c9367 100644
--- 
a/regression-test/suites/external_table_p2/refactor_catalog_param/azure_blob_all_test.groovy
+++ 
b/regression-test/suites/external_table_p2/refactor_catalog_param/azure_blob_all_test.groovy
@@ -35,6 +35,7 @@ suite("azure_blob_all_test", 
"p2,external,new_catalog_property") {
     
     def testIcebergTest = { String storage_props,String 
iceberg_fs_catalog_name, String protocol,String hdfsLocationType ->
         
+        iceberg_fs_catalog_name = iceberg_fs_catalog_name + "_" + 
ThreadLocalRandom.current().nextInt(100) 
         sql """
          drop catalog if exists ${iceberg_fs_catalog_name};
         """
@@ -52,7 +53,7 @@ suite("azure_blob_all_test", 
"p2,external,new_catalog_property") {
             """
 
         sql """
-        drop database if exists ${iceberg_fs_catalog_name}_db_test;
+        drop database if exists ${iceberg_fs_catalog_name}_db_test force;
         """
         sql """
         create database ${iceberg_fs_catalog_name}_db_test;
@@ -76,7 +77,7 @@ suite("azure_blob_all_test", 
"p2,external,new_catalog_property") {
         drop table if exists ${iceberg_fs_catalog_name}_table_test;
     """
         sql """
-        drop database if exists ${iceberg_fs_catalog_name}_db_test;
+        drop database if exists ${iceberg_fs_catalog_name}_db_test force;
     """
         sql """
         drop catalog if exists ${iceberg_fs_catalog_name};
diff --git 
a/regression-test/suites/external_table_p2/refactor_catalog_param/iceberg_on_hms_and_filesystem_and_dlf.groovy
 
b/regression-test/suites/external_table_p2/refactor_catalog_param/iceberg_on_hms_and_filesystem_and_dlf.groovy
index 873ce242a8e..1647b001d19 100644
--- 
a/regression-test/suites/external_table_p2/refactor_catalog_param/iceberg_on_hms_and_filesystem_and_dlf.groovy
+++ 
b/regression-test/suites/external_table_p2/refactor_catalog_param/iceberg_on_hms_and_filesystem_and_dlf.groovy
@@ -14,6 +14,9 @@
 // KIND, either express or implied.  See the License for the
 // specific language governing permissions and limitations
 // under the License.
+
+import java.util.concurrent.ThreadLocalRandom
+
 import static groovy.test.GroovyAssert.shouldFail;
 suite("iceberg_on_hms_and_filesystem_and_dlf", 
"p2,external,new_catalog_property") {
 
@@ -33,7 +36,8 @@ suite("iceberg_on_hms_and_filesystem_and_dlf", 
"p2,external,new_catalog_property
             switch ${catalog_name};
         """
 
-        def db_name = prefix + "_db"
+        def db_name = prefix + "_db"+ ThreadLocalRandom.current().nextInt(100);
+        // Check if database exists
         sql """
             DROP DATABASE IF EXISTS ${db_name} FORCE;
         """


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

Reply via email to