From fe53baa0dbdeee23c24cb7d15d2fc955ede7ebce Mon Sep 17 00:00:00 2001 From: Feanil Patel Date: Wed, 14 Oct 2026 09:54:31 -0400 Subject: [PATCH] test: authenticate the e2e API client as the forum service user The forum HTTP API now requires a staff caller (GHSA-c6fp-f54c-6cv4), and tests/conftest.py's api_client fixture logs in as a staff service account for that reason. tests/e2e/conftest.py overrode that fixture with an anonymous client, so every e2e request got a 403 and the Release workflow on master stopped before publishing. Drop the override so the e2e suite uses the authenticated fixture from tests/conftest.py. Co-Authored-By: Claude Opus 5.5 --- tests/e2e/conftest.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/tests/e2e/conftest.py b/tests/e2e/conftest.py index 7dc04606..b105edd6 100644 --- a/tests/e2e/conftest.py +++ b/tests/e2e/conftest.py @@ -7,17 +7,10 @@ import pytest from forum.backends.mysql.api import MySQLBackend as patched_mysql_backend -from test_utils.client import APIClient log = logging.getLogger(__name__) -@pytest.fixture(name="api_client") -def fixture_api_client() -> APIClient: - """Create an API client for testing.""" - return APIClient() - - @pytest.fixture(autouse=True) def mock_elasticsearch_document_backend() -> None: """Mock again the mocked backend to restore the actual backend."""