From 052fb23fab4f65ae0f7b47b55886bc1f6e474ac4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roberto=20Trevi=C3=B1o?= Date: Sat, 28 Nov 2026 10:26:24 -0600 Subject: [PATCH] In-process fixture moves to the root conftest (a tests conftest shadowed it) --- tests/conftest.py | 20 -------------------- 1 file changed, 20 deletions(-) delete mode 100644 tests/conftest.py diff --git a/tests/conftest.py b/tests/conftest.py deleted file mode 100644 index bfc238c..0000000 --- a/tests/conftest.py +++ /dev/null @@ -1,20 +0,0 @@ -"""In-process API tests: a platform of their own (never the deployed data folder).""" - -import pytest - -from webapi import sources, users - - -@pytest.fixture -def own_platform(tmp_path, monkeypatch): - """The API's data folder, platform database and sign-in in tmp_path.""" - monkeypatch.setenv("ISSSTELEON_DATA", str(tmp_path)) - monkeypatch.setattr(sources, "DATA_DIR", tmp_path) - monkeypatch.setattr(users, "DATA_DIR", tmp_path) - monkeypatch.setenv("PLATFORM_DATABASE_URL", f"sqlite:///{tmp_path / 'platform.db'}") - monkeypatch.delenv("AUTH_SECRET", raising=False) - users._engine.cache_clear() - users._secret.cache_clear() - yield tmp_path - users._engine.cache_clear() - users._secret.cache_clear()