mirror of
http://112.124.100.131/huang.ze/ebiz-dify-ai.git
synced 2025-12-09 02:46:52 +08:00
refactor: use dify_config to replace legacy usage of flask app's config (#9089)
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import pytest
|
||||
|
||||
from app_factory import create_app
|
||||
from configs import dify_config
|
||||
|
||||
mock_user = type(
|
||||
"MockUser",
|
||||
@@ -20,5 +21,5 @@ mock_user = type(
|
||||
@pytest.fixture
|
||||
def app():
|
||||
app = create_app()
|
||||
app.config["LOGIN_DISABLED"] = True
|
||||
dify_config.LOGIN_DISABLED = True
|
||||
return app
|
||||
|
||||
@@ -25,7 +25,7 @@ class VolcengineTosTest:
|
||||
return cls._instance
|
||||
|
||||
def __init__(self):
|
||||
self.storage = VolcengineTosStorage(app=Flask(__name__))
|
||||
self.storage = VolcengineTosStorage()
|
||||
self.storage.bucket_name = get_example_bucket()
|
||||
self.storage.client = TosClientV2(
|
||||
ak="dify",
|
||||
|
||||
Reference in New Issue
Block a user