From b70fb4ca8e4b6908965f7515ecce115b12b2c868 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B0=A2=E5=81=A5?= Date: Fri, 7 Jul 2023 12:46:07 +0800 Subject: [PATCH] [fix](test) build internal table for TPCHTest to fix testRank (#21566) --- .../apache/doris/nereids/datasets/tpch/TPCHTestBase.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/fe/fe-core/src/test/java/org/apache/doris/nereids/datasets/tpch/TPCHTestBase.java b/fe/fe-core/src/test/java/org/apache/doris/nereids/datasets/tpch/TPCHTestBase.java index 71dddf165c..a0c9b77f7e 100644 --- a/fe/fe-core/src/test/java/org/apache/doris/nereids/datasets/tpch/TPCHTestBase.java +++ b/fe/fe-core/src/test/java/org/apache/doris/nereids/datasets/tpch/TPCHTestBase.java @@ -17,9 +17,18 @@ package org.apache.doris.nereids.datasets.tpch; +import org.apache.doris.catalog.InternalSchemaInitializer; +import org.apache.doris.common.FeConstants; + public abstract class TPCHTestBase extends AnalyzeCheckTestBase { @Override protected void runBeforeAll() throws Exception { + // The internal table for TPCHTestBase is constructed in order to facilitate + // the execution of certain tests that require the invocation of a deriveStats job. + // This deriveStats job is responsible for retrieving statistics from the aforementioned + // internal table. + FeConstants.disableInternalSchemaDb = false; + new InternalSchemaInitializer().run(); createDatabase("tpch"); connectContext.setDatabase("default_cluster:tpch"); TPCHUtils.createTables(this);