MCPcopy Create free account
hub / github.com/Tron521/codex-console-temp / FakeSession

Class FakeSession

tests/test_new_api_upload.py:49–58  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47 calls = []
48
49 class FakeSession:
50 def post(self, url, **kwargs):
51 calls.append({"url": url, "kwargs": kwargs})
52 if url.endswith("/api/user/login"):
53 response = FakeResponse(status_code=200, payload={"success": True})
54 response.cookies = {"session": "cookie"}
55 return response
56 if url.endswith("/api/channel/"):
57 return FakeResponse(status_code=200, payload={"success": True})
58 raise AssertionError(url)
59
60 def fake_create_session(api_url, username, password):
61 session = FakeSession()

Callers 1

fake_create_sessionFunction · 0.85

Calls

no outgoing calls

Tested by 1

fake_create_sessionFunction · 0.68