refactor(desktop): share HTTP test fakes across adapter tests

Merged
CH
3mo ago
+184-358

Summary

  • Extract jsonResponse, RecordedRequest, and a recording-fetch factory into apps/desktop/tests/support/http-fake.ts, and re-export HTTP_STATUS from product code so adapter tests stop restating 401.
  • Leave each provider's route table beside the adapter it describes; those tables genuinely differ.
  • RealtimeVoiceSession is not split in this PR. The WebRTC transport looks separable from conversation logic, but #startResponse must stay the single enforcement point for "only a developer-opened turn may act."

Evidence

  • Platform-independent checks: ./scripts/check.sh passed locally (661 desktop tests)
  • macOS Electron verification (./scripts/verify.sh): not run (test-only change)

Automated visual evidence

Download the deterministic macOS evidence · workflow run

  • Commit: b8008614308cbcb8e854f1beb4ea0ec07255b74f
  • Scenario: smoke
  • Physical-notch check: not performed by CI

Physical-device evidence

  • Screenshot or screen recording: not attached
  • Physical-notch check: not performed
  • Device/display configuration: not recorded

Notes

  • Blockers or follow-up verification: None
  • Split recommendation is recorded for a follow-up; this PR only lands the shared HTTP fakes.

Made with Cursor