From 4adfcc41315cfe6ec55a59bc5e4a9a0907d5eddf Mon Sep 17 00:00:00 2001 From: kqjy Date: Sun, 18 Jan 2026 21:53:39 +0800 Subject: [PATCH] Improve pytest tests --- tests/conftest.py | 1 + tests/test_kms_api.py | 1 + tests/test_ui_pagination.py | 1 + 3 files changed, 3 insertions(+) diff --git a/tests/conftest.py b/tests/conftest.py index 5b216db..59cb5dd 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -35,6 +35,7 @@ def app(tmp_path: Path): flask_app = create_api_app( { "TESTING": True, + "SECRET_KEY": "testing", "STORAGE_ROOT": storage_root, "IAM_CONFIG": iam_config, "BUCKET_POLICY_PATH": bucket_policies, diff --git a/tests/test_kms_api.py b/tests/test_kms_api.py index d52dda0..97429c8 100644 --- a/tests/test_kms_api.py +++ b/tests/test_kms_api.py @@ -15,6 +15,7 @@ def kms_client(tmp_path): app = create_app({ "TESTING": True, + "SECRET_KEY": "testing", "STORAGE_ROOT": str(tmp_path / "storage"), "IAM_CONFIG": str(tmp_path / "iam.json"), "BUCKET_POLICY_PATH": str(tmp_path / "policies.json"), diff --git a/tests/test_ui_pagination.py b/tests/test_ui_pagination.py index 5d5bee0..e6f34d1 100644 --- a/tests/test_ui_pagination.py +++ b/tests/test_ui_pagination.py @@ -28,6 +28,7 @@ def _make_app(tmp_path: Path): flask_app = create_app( { "TESTING": True, + "SECRET_KEY": "testing", "WTF_CSRF_ENABLED": False, "STORAGE_ROOT": storage_root, "IAM_CONFIG": iam_config,