Every test client speaks to 127.0.0.1, since an open door now answers 421 to a Host that is not loopback
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
6513e2ab95
commit
6e51134477
12 files changed
+19
-19
No files matched your search
@@ -36,7 +36,7 @@ def store(app: FastAPI) -> Store:
|
||||
|
||||
@pytest.fixture
|
||||
def client(app: FastAPI) -> Iterator[TestClient]:
|
||||
with TestClient(app) as c:
|
||||
with TestClient(app, base_url="http://127.0.0.1") as c:
|
||||
yield c
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@ def test_fetch_text_answers_with_the_viewing_agents_vote(
|
||||
def test_a_stage_shows_the_model_that_will_answer(tmp_path: Path) -> None:
|
||||
config = Config(database=tmp_path / "x.db")
|
||||
app = create_app(config)
|
||||
with TestClient(app) as client:
|
||||
with TestClient(app, base_url="http://127.0.0.1") as client:
|
||||
by_name = {s["name"]: s for s in client.get("/api/stages").json()}
|
||||
assert by_name["extract"]["model"] == config.extract.model
|
||||
config.agent.model = "claude-opus-4-1"
|
||||
|
||||
Reference in new issue
Block a user