Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.
Python agentagentic-aiagentic-frameworkagentic-workflowaiautomationclaudedeepseekgenaigptllmlow-codemcpnextjsno-codeopenaipythonskillsworkflow
refactor(api): replace test fixture side-effect imports (#34421)
99cd406d2794ef
diff --git a/api/.ruff.toml b/api/.ruff.tomlindex 4b1252a8613..2a825f1ef05 100644--- a/api/.ruff.toml+++ b/api/.ruff.toml@@ -115,12 +115,6 @@ ignore = ["controllers/console/human_input_form.py" = ["TID251"]"controllers/web/human_input_form.py" = ["TID251"]-[lint.pyflakes]-allowed-unused-imports = [- "tests.integration_tests",- "tests.unit_tests",-]-[lint.flake8-tidy-imports][lint.flake8-tidy-imports.banned-api."flask_restx.reqparse"]diff --git a/api/tests/integration_tests/plugin/__mock/http.py b/api/tests/integration_tests/plugin/__mock/http.pyindex d5cf47e2c24..b39e4a8e762 100644--- a/api/tests/integration_tests/plugin/__mock/http.py+++ b/api/tests/integration_tests/plugin/__mock/http.py@@ -4,23 +4,28 @@ from typing import Literalimport httpximport pytest-from core.plugin.entities.plugin_daemon import PluginDaemonBasicResponse+from core.plugin.entities.plugin_daemon import PluginDaemonBasicResponse, PluginToolProviderEntityfrom core.tools.entities.common_entities import I18nObject-from core.tools.entities.tool_entities import ToolProviderEntity, ToolProviderIdentity+from core.tools.entities.tool_entities import ToolProviderEntityWithPlugin, ToolProviderIdentityclass MockedHttp:@classmethod- def list_tools(cls) -> list[ToolProviderEntity]:+ def list_tools(cls) -> list[PluginToolProviderEntity]:return [- ToolProviderEntity(- identity=ToolProviderIdentity(- author="Yeuoly",- name="Yeuoly",- description=I18nObject(en_US="Yeuoly"),- icon="ssss.svg",- label=I18nObject(en_US="Yeuoly"),- )+ PluginToolProviderEntity(+ provider="Yeuoly",+ plugin_unique_identifier="langgenius/yeuoly:0.0.1@mock",+ plugin_id="mock-plugin",+ declaration=ToolProviderEntityWithPlugin(+ identity=ToolProviderIdentity(+ author="Yeuoly",+ name="Yeuoly",+ description=I18nObject(en_US="Yeuoly"),+ icon="ssss.svg",+ label=I18nObject(en_US="Yeuoly"),+ )+ ),)]@@ -33,7 +38,7 @@ class MockedHttp:"""request = httpx.Request(method, url)if url.endswith("/tools"):- content = PluginDaemonBasicResponse[list[ToolProviderEntity]](+ content = PluginDaemonBasicResponse[list[PluginToolProviderEntity]](code=0, message="success", data=cls.list_tools()).model_dump_json()else:diff --git a/api/tests/integration_tests/plugin/tools/test_fetch_all_tools.py b/api/tests/integration_tests/plugin/tools/test_fetch_all_tools.pyindex b6d583e3389..9a4450a454f 100644--- a/api/tests/integration_tests/plugin/tools/test_fetch_all_tools.py+++ b/api/tests/integration_tests/plugin/tools/test_fetch_all_tools.py@@ -1,5 +1,6 @@from core.plugin.impl.tool import PluginToolManager-from tests.integration_tests.plugin.__mock.http import setup_http_mock++pytest_plugins = ("tests.integration_tests.plugin.__mock.http",)def test_fetch_all_plugin_tools(setup_http_mock):diff --git a/api/tests/integration_tests/tools/api_tool/test_api_tool.py b/api/tests/integration_tests/tools/api_tool/test_api_tool.pyindex e6375302651..9079aa7d6d2 100644--- a/api/tests/integration_tests/tools/api_tool/test_api_tool.py+++ b/api/tests/integration_tests/tools/api_tool/test_api_tool.py@@ -3,7 +3,8 @@ from core.tools.custom_tool.tool import ApiToolfrom core.tools.entities.common_entities import I18nObjectfrom core.tools.entities.tool_bundle import ApiToolBundlefrom core.tools.entities.tool_entities import ToolEntity, ToolIdentity-from tests.integration_tests.tools.__mock.http import setup_http_mock++pytest_plugins = ("tests.integration_tests.tools.__mock.http",)tool_bundle = {"server_url": "http://www.example.com/{path_param}",diff --git a/api/tests/integration_tests/vdb/analyticdb/test_analyticdb.py b/api/tests/integration_tests/vdb/analyticdb/test_analyticdb.pyindex 5dd4754e8ef..09815238097 100644--- a/api/tests/integration_tests/vdb/analyticdb/test_analyticdb.py+++ b/api/tests/integration_tests/vdb/analyticdb/test_analyticdb.py@@ -1,7 +1,9 @@from core.rag.datasource.vdb.analyticdb.analyticdb_vector import AnalyticdbVectorfrom core.rag.datasource.vdb.analyticdb.analyticdb_vector_openapi import AnalyticdbVectorOpenAPIConfigfrom core.rag.datasource.vdb.analyticdb.analyticdb_vector_sql import AnalyticdbVectorBySqlConfig-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest++pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)class AnalyticdbVectorTest(AbstractVectorTest):diff --git a/api/tests/integration_tests/vdb/baidu/test_baidu.py b/api/tests/integration_tests/vdb/baidu/test_baidu.pyindex 25989958d99..716f88af672 100644--- a/api/tests/integration_tests/vdb/baidu/test_baidu.py+++ b/api/tests/integration_tests/vdb/baidu/test_baidu.py@@ -1,6 +1,10 @@from core.rag.datasource.vdb.baidu.baidu_vector import BaiduConfig, BaiduVector-from tests.integration_tests.vdb.__mock.baiduvectordb import setup_baiduvectordb_mock-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text++pytest_plugins = (+ "tests.integration_tests.vdb.test_vector_store",+ "tests.integration_tests.vdb.__mock.baiduvectordb",+)class BaiduVectorTest(AbstractVectorTest):diff --git a/api/tests/integration_tests/vdb/chroma/test_chroma.py b/api/tests/integration_tests/vdb/chroma/test_chroma.pyindex ac7b5cbda45..52beba9979d 100644--- a/api/tests/integration_tests/vdb/chroma/test_chroma.py+++ b/api/tests/integration_tests/vdb/chroma/test_chroma.py@@ -4,9 +4,10 @@ from core.rag.datasource.vdb.chroma.chroma_vector import ChromaConfig, ChromaVecfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,get_example_text,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class ChromaVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/couchbase/test_couchbase.py b/api/tests/integration_tests/vdb/couchbase/test_couchbase.pyindex eef1ee4e759..0371f042330 100644--- a/api/tests/integration_tests/vdb/couchbase/test_couchbase.py+++ b/api/tests/integration_tests/vdb/couchbase/test_couchbase.py@@ -4,9 +4,10 @@ import timefrom core.rag.datasource.vdb.couchbase.couchbase_vector import CouchbaseConfig, CouchbaseVectorfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+def wait_for_healthy_container(service_name="couchbase-server", timeout=300):start_time = time.time()diff --git a/api/tests/integration_tests/vdb/elasticsearch/test_elasticsearch.py b/api/tests/integration_tests/vdb/elasticsearch/test_elasticsearch.pyindex a5ff5b9e822..970d2cce1ae 100644--- a/api/tests/integration_tests/vdb/elasticsearch/test_elasticsearch.py+++ b/api/tests/integration_tests/vdb/elasticsearch/test_elasticsearch.py@@ -1,9 +1,10 @@from core.rag.datasource.vdb.elasticsearch.elasticsearch_vector import ElasticSearchConfig, ElasticSearchVectorfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class ElasticSearchVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/hologres/test_hologres.py b/api/tests/integration_tests/vdb/hologres/test_hologres.pyindex ff2be88ef18..d81e18841e0 100644--- a/api/tests/integration_tests/vdb/hologres/test_hologres.py+++ b/api/tests/integration_tests/vdb/hologres/test_hologres.py@@ -6,8 +6,12 @@ from holo_search_sdk.types import BaseQuantizationType, DistanceType, TokenizerTfrom core.rag.datasource.vdb.hologres.hologres_vector import HologresVector, HologresVectorConfigfrom core.rag.models.document import Document-from tests.integration_tests.vdb.__mock.hologres import setup_hologres_mock-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text++pytest_plugins = (+ "tests.integration_tests.vdb.test_vector_store",+ "tests.integration_tests.vdb.__mock.hologres",+)MOCK = os.getenv("MOCK_SWITCH", "false").lower() == "true"diff --git a/api/tests/integration_tests/vdb/huawei/test_huawei_cloud.py b/api/tests/integration_tests/vdb/huawei/test_huawei_cloud.pyindex 943b2bc877a..01f511358af 100644--- a/api/tests/integration_tests/vdb/huawei/test_huawei_cloud.py+++ b/api/tests/integration_tests/vdb/huawei/test_huawei_cloud.py@@ -1,6 +1,10 @@from core.rag.datasource.vdb.huawei.huawei_cloud_vector import HuaweiCloudVector, HuaweiCloudVectorConfig-from tests.integration_tests.vdb.__mock.huaweicloudvectordb import setup_client_mock-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text++pytest_plugins = (+ "tests.integration_tests.vdb.test_vector_store",+ "tests.integration_tests.vdb.__mock.huaweicloudvectordb",+)class HuaweiCloudVectorTest(AbstractVectorTest):diff --git a/api/tests/integration_tests/vdb/iris/test_iris.py b/api/tests/integration_tests/vdb/iris/test_iris.pyindex 49f6857743e..4b2da8387bd 100644--- a/api/tests/integration_tests/vdb/iris/test_iris.py+++ b/api/tests/integration_tests/vdb/iris/test_iris.py@@ -3,9 +3,10 @@from core.rag.datasource.vdb.iris.iris_vector import IrisVector, IrisVectorConfigfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class IrisVectorTest(AbstractVectorTest):"""Test suite for IRIS vector store implementation."""diff --git a/api/tests/integration_tests/vdb/lindorm/test_lindorm.py b/api/tests/integration_tests/vdb/lindorm/test_lindorm.pyindex 6708ab80956..b24498fdfdd 100644--- a/api/tests/integration_tests/vdb/lindorm/test_lindorm.py+++ b/api/tests/integration_tests/vdb/lindorm/test_lindorm.py@@ -1,7 +1,9 @@import osfrom core.rag.datasource.vdb.lindorm.lindorm_vector import LindormVectorStore, LindormVectorStoreConfig-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest++pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)class Config:diff --git a/api/tests/integration_tests/vdb/matrixone/test_matrixone.py b/api/tests/integration_tests/vdb/matrixone/test_matrixone.pyindex c4056db63e2..fe592f6699c 100644--- a/api/tests/integration_tests/vdb/matrixone/test_matrixone.py+++ b/api/tests/integration_tests/vdb/matrixone/test_matrixone.py@@ -1,9 +1,10 @@from core.rag.datasource.vdb.matrixone.matrixone_vector import MatrixoneConfig, MatrixoneVectorfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class MatrixoneVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/milvus/test_milvus.py b/api/tests/integration_tests/vdb/milvus/test_milvus.pyindex 0e13f9369e8..b5fc4b4d109 100644--- a/api/tests/integration_tests/vdb/milvus/test_milvus.py+++ b/api/tests/integration_tests/vdb/milvus/test_milvus.py@@ -2,9 +2,10 @@ from core.rag.datasource.vdb.milvus.milvus_vector import MilvusConfig, MilvusVecfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,get_example_text,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class MilvusVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/myscale/test_myscale.py b/api/tests/integration_tests/vdb/myscale/test_myscale.pyindex 55b2fde4276..74cefad2af7 100644--- a/api/tests/integration_tests/vdb/myscale/test_myscale.py+++ b/api/tests/integration_tests/vdb/myscale/test_myscale.py@@ -1,9 +1,10 @@from core.rag.datasource.vdb.myscale.myscale_vector import MyScaleConfig, MyScaleVectorfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class MyScaleVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/oceanbase/test_oceanbase.py b/api/tests/integration_tests/vdb/oceanbase/test_oceanbase.pyindex 2db6732354b..410de2c5ad2 100644--- a/api/tests/integration_tests/vdb/oceanbase/test_oceanbase.py+++ b/api/tests/integration_tests/vdb/oceanbase/test_oceanbase.py@@ -6,9 +6,10 @@ from core.rag.datasource.vdb.oceanbase.oceanbase_vector import ()from tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+@pytest.fixturedef oceanbase_vector():diff --git a/api/tests/integration_tests/vdb/opengauss/test_opengauss.py b/api/tests/integration_tests/vdb/opengauss/test_opengauss.pyindex 338077bbff3..78436a19eef 100644--- a/api/tests/integration_tests/vdb/opengauss/test_opengauss.py+++ b/api/tests/integration_tests/vdb/opengauss/test_opengauss.py@@ -5,9 +5,10 @@ import psycopg2from core.rag.datasource.vdb.opengauss.opengauss import OpenGauss, OpenGaussConfigfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class OpenGaussTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/oracle/test_oraclevector.py b/api/tests/integration_tests/vdb/oracle/test_oraclevector.pyindex 76e8b7bccd3..8920dc97ebb 100644--- a/api/tests/integration_tests/vdb/oracle/test_oraclevector.py+++ b/api/tests/integration_tests/vdb/oracle/test_oraclevector.py@@ -3,9 +3,10 @@ from core.rag.models.document import Documentfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,get_example_text,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class OracleVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/pgvecto_rs/test_pgvecto_rs.py b/api/tests/integration_tests/vdb/pgvecto_rs/test_pgvecto_rs.pyindex 6497f47deb9..6210613d421 100644--- a/api/tests/integration_tests/vdb/pgvecto_rs/test_pgvecto_rs.py+++ b/api/tests/integration_tests/vdb/pgvecto_rs/test_pgvecto_rs.py@@ -2,9 +2,10 @@ from core.rag.datasource.vdb.pgvecto_rs.pgvecto_rs import PGVectoRS, PgvectoRSCofrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,get_example_text,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class PGVectoRSVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/pgvector/test_pgvector.py b/api/tests/integration_tests/vdb/pgvector/test_pgvector.pyindex 3d2cfde5d1d..4fdeca5a3a8 100644--- a/api/tests/integration_tests/vdb/pgvector/test_pgvector.py+++ b/api/tests/integration_tests/vdb/pgvector/test_pgvector.py@@ -1,10 +1,10 @@from core.rag.datasource.vdb.pgvector.pgvector import PGVector, PGVectorConfigfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- get_example_text,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class PGVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/pyvastbase/test_vastbase_vector.py b/api/tests/integration_tests/vdb/pyvastbase/test_vastbase_vector.pyindex 02931fef5a2..a47f13625cd 100644--- a/api/tests/integration_tests/vdb/pyvastbase/test_vastbase_vector.py+++ b/api/tests/integration_tests/vdb/pyvastbase/test_vastbase_vector.py@@ -1,9 +1,10 @@from core.rag.datasource.vdb.pyvastbase.vastbase_vector import VastbaseVector, VastbaseVectorConfigfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class VastbaseVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/qdrant/test_qdrant.py b/api/tests/integration_tests/vdb/qdrant/test_qdrant.pyindex a2bf10001a9..709cc2e14ef 100644--- a/api/tests/integration_tests/vdb/qdrant/test_qdrant.py+++ b/api/tests/integration_tests/vdb/qdrant/test_qdrant.py@@ -4,9 +4,10 @@ from core.rag.datasource.vdb.qdrant.qdrant_vector import QdrantConfig, QdrantVecfrom core.rag.models.document import Documentfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class QdrantVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/tablestore/test_tablestore.py b/api/tests/integration_tests/vdb/tablestore/test_tablestore.pyindex aebf3fbda10..b60e26a881d 100644--- a/api/tests/integration_tests/vdb/tablestore/test_tablestore.py+++ b/api/tests/integration_tests/vdb/tablestore/test_tablestore.py@@ -12,9 +12,10 @@ from tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,get_example_document,get_example_text,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class TableStoreVectorTest(AbstractVectorTest):def __init__(self, normalize_full_text_score: bool = False):diff --git a/api/tests/integration_tests/vdb/tcvectordb/test_tencent.py b/api/tests/integration_tests/vdb/tcvectordb/test_tencent.pyindex 9227bbdcd65..3d6deff2a06 100644--- a/api/tests/integration_tests/vdb/tcvectordb/test_tencent.py+++ b/api/tests/integration_tests/vdb/tcvectordb/test_tencent.py@@ -1,8 +1,12 @@from unittest.mock import MagicMockfrom core.rag.datasource.vdb.tencent.tencent_vector import TencentConfig, TencentVector-from tests.integration_tests.vdb.__mock.tcvectordb import setup_tcvectordb_mock-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text++pytest_plugins = (+ "tests.integration_tests.vdb.test_vector_store",+ "tests.integration_tests.vdb.__mock.tcvectordb",+)mock_client = MagicMock()mock_client.list_databases.return_value = [{"name": "test"}]diff --git a/api/tests/integration_tests/vdb/tidb_vector/test_tidb_vector.py b/api/tests/integration_tests/vdb/tidb_vector/test_tidb_vector.pyindex dec63c64761..14c6d1c67c5 100644--- a/api/tests/integration_tests/vdb/tidb_vector/test_tidb_vector.py+++ b/api/tests/integration_tests/vdb/tidb_vector/test_tidb_vector.py@@ -2,7 +2,9 @@ import pytestfrom core.rag.datasource.vdb.tidb_vector.tidb_vector import TiDBVector, TiDBVectorConfigfrom models.dataset import Document-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text++pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)@pytest.fixturediff --git a/api/tests/integration_tests/vdb/upstash/test_upstash_vector.py b/api/tests/integration_tests/vdb/upstash/test_upstash_vector.pyindex 23470474ff6..8cea0a05eb6 100644--- a/api/tests/integration_tests/vdb/upstash/test_upstash_vector.py+++ b/api/tests/integration_tests/vdb/upstash/test_upstash_vector.py@@ -1,8 +1,9 @@from core.rag.datasource.vdb.upstash.upstash_vector import UpstashVector, UpstashVectorConfigfrom core.rag.models.document import Document-from tests.integration_tests.vdb.__mock.upstashvectordb import setup_upstashvector_mockfrom tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text+pytest_plugins = ("tests.integration_tests.vdb.__mock.upstashvectordb",)+class UpstashVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/vdb/vikingdb/test_vikingdb.py b/api/tests/integration_tests/vdb/vikingdb/test_vikingdb.pyindex 2572012ea03..56311acd25e 100644--- a/api/tests/integration_tests/vdb/vikingdb/test_vikingdb.py+++ b/api/tests/integration_tests/vdb/vikingdb/test_vikingdb.py@@ -1,6 +1,10 @@from core.rag.datasource.vdb.vikingdb.vikingdb_vector import VikingDBConfig, VikingDBVector-from tests.integration_tests.vdb.__mock.vikingdb import setup_vikingdb_mock-from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text, setup_mock_redis+from tests.integration_tests.vdb.test_vector_store import AbstractVectorTest, get_example_text++pytest_plugins = (+ "tests.integration_tests.vdb.test_vector_store",+ "tests.integration_tests.vdb.__mock.vikingdb",+)class VikingDBVectorTest(AbstractVectorTest):diff --git a/api/tests/integration_tests/vdb/weaviate/test_weaviate.py b/api/tests/integration_tests/vdb/weaviate/test_weaviate.pyindex a6f55420d31..a1d9850979f 100644--- a/api/tests/integration_tests/vdb/weaviate/test_weaviate.py+++ b/api/tests/integration_tests/vdb/weaviate/test_weaviate.py@@ -1,9 +1,10 @@from core.rag.datasource.vdb.weaviate.weaviate_vector import WeaviateConfig, WeaviateVectorfrom tests.integration_tests.vdb.test_vector_store import (AbstractVectorTest,- setup_mock_redis,)+pytest_plugins = ("tests.integration_tests.vdb.test_vector_store",)+class WeaviateVectorTest(AbstractVectorTest):def __init__(self):diff --git a/api/tests/integration_tests/workflow/nodes/test_code.py b/api/tests/integration_tests/workflow/nodes/test_code.pyindex ce0c8bf8ca8..4f41396c22b 100644--- a/api/tests/integration_tests/workflow/nodes/test_code.py+++ b/api/tests/integration_tests/workflow/nodes/test_code.py@@ -13,9 +13,10 @@ from configs import dify_configfrom core.app.entities.app_invoke_entities import InvokeFrom, UserFromfrom core.workflow.node_factory import DifyNodeFactoryfrom core.workflow.system_variables import build_system_variables-from tests.integration_tests.workflow.nodes.__mock.code_executor import setup_code_executor_mockfrom tests.workflow_test_utils import build_test_graph_init_params+pytest_plugins = ("tests.integration_tests.workflow.nodes.__mock.code_executor",)+CODE_MAX_STRING_LENGTH = dify_config.CODE_MAX_STRING_LENGTHdiff --git a/api/tests/integration_tests/workflow/nodes/test_http.py b/api/tests/integration_tests/workflow/nodes/test_http.pyindex ce18486fafc..b1f937e7388 100644--- a/api/tests/integration_tests/workflow/nodes/test_http.py+++ b/api/tests/integration_tests/workflow/nodes/test_http.py@@ -16,9 +16,10 @@ from core.tools.tool_file_manager import ToolFileManagerfrom core.workflow.node_factory import DifyNodeFactoryfrom core.workflow.node_runtime import DifyFileReferenceFactoryfrom core.workflow.system_variables import build_system_variables-from tests.integration_tests.workflow.nodes.__mock.http import setup_http_mockfrom tests.workflow_test_utils import build_test_graph_init_params+pytest_plugins = ("tests.integration_tests.workflow.nodes.__mock.http",)+HTTP_REQUEST_CONFIG = HttpRequestNodeConfig(max_connect_timeout=dify_config.HTTP_REQUEST_MAX_CONNECT_TIMEOUT,max_read_timeout=dify_config.HTTP_REQUEST_MAX_READ_TIMEOUT,diff --git a/api/tests/integration_tests/workflow/nodes/test_parameter_extractor.py b/api/tests/integration_tests/workflow/nodes/test_parameter_extractor.pyindex 3bf44df349c..fe512c25856 100644--- a/api/tests/integration_tests/workflow/nodes/test_parameter_extractor.py+++ b/api/tests/integration_tests/workflow/nodes/test_parameter_extractor.py@@ -17,8 +17,7 @@ from extensions.ext_database import dbfrom tests.integration_tests.workflow.nodes.__mock.model import get_mocked_fetch_model_instancefrom tests.workflow_test_utils import build_test_graph_init_params-"""FOR MOCK FIXTURES, DO NOT REMOVE"""-from tests.integration_tests.model_runtime.__mock.plugin_daemon import setup_model_mock+pytest_plugins = ("tests.integration_tests.model_runtime.__mock.plugin_daemon",)def get_mocked_fetch_memory(memory_text: str):diff --git a/api/tests/unit_tests/oss/aliyun_oss/aliyun_oss/test_aliyun_oss.py b/api/tests/unit_tests/oss/aliyun_oss/aliyun_oss/test_aliyun_oss.pyindex 10388a88809..52abfdd72ed 100644--- a/api/tests/unit_tests/oss/aliyun_oss/aliyun_oss/test_aliyun_oss.py+++ b/api/tests/unit_tests/oss/aliyun_oss/aliyun_oss/test_aliyun_oss.py@@ -4,13 +4,14 @@ import pytestfrom oss2 import Authfrom extensions.storage.aliyun_oss_storage import AliyunOssStorage-from tests.unit_tests.oss.__mock.aliyun_oss import setup_aliyun_oss_mockfrom tests.unit_tests.oss.__mock.base import (BaseStorageTest,get_example_bucket,get_example_folder,)+pytest_plugins = ("tests.unit_tests.oss.__mock.aliyun_oss",)+class TestAliyunOss(BaseStorageTest):@pytest.fixture(autouse=True)diff --git a/api/tests/unit_tests/oss/tencent_cos/test_tencent_cos.py b/api/tests/unit_tests/oss/tencent_cos/test_tencent_cos.pyindex d54116555ee..2802a2f1e39 100644--- a/api/tests/unit_tests/oss/tencent_cos/test_tencent_cos.py+++ b/api/tests/unit_tests/oss/tencent_cos/test_tencent_cos.py@@ -8,7 +8,8 @@ from tests.unit_tests.oss.__mock.base import (BaseStorageTest,get_example_bucket,)-from tests.unit_tests.oss.__mock.tencent_cos import setup_tencent_cos_mock++pytest_plugins = ("tests.unit_tests.oss.__mock.tencent_cos",)class TestTencentCos(BaseStorageTest):diff --git a/api/tests/unit_tests/oss/volcengine_tos/test_volcengine_tos.py b/api/tests/unit_tests/oss/volcengine_tos/test_volcengine_tos.pyindex a06623a69e4..8adea888115 100644--- a/api/tests/unit_tests/oss/volcengine_tos/test_volcengine_tos.py+++ b/api/tests/unit_tests/oss/volcengine_tos/test_volcengine_tos.py@@ -8,7 +8,8 @@ from tests.unit_tests.oss.__mock.base import (BaseStorageTest,get_example_bucket,)-from tests.unit_tests.oss.__mock.volcengine_tos import setup_volcengine_tos_mock++pytest_plugins = ("tests.unit_tests.oss.__mock.volcengine_tos",)class TestVolcengineTos(BaseStorageTest):