fix(claude-code): remove Roo Code Cloud changes and update tests

- Rebased on main to remove unrelated terms.md changes
- Updated streaming-client tests to match OAuth compatibility changes:
  - Removed expectation for fine-grained-tool-streaming beta header
  - Updated userAgent regex to match claude-cli format
This commit is contained in:
Roo Code 2026-01-11 17:33:29 +00:00
parent a2ea1acd3e
commit dc48e00fad

View file

@ -14,11 +14,12 @@ describe("Claude Code Streaming Client", () => {
expect(CLAUDE_CODE_API_CONFIG.defaultBetas).toContain("claude-code-20250219")
expect(CLAUDE_CODE_API_CONFIG.defaultBetas).toContain("oauth-2025-04-20")
expect(CLAUDE_CODE_API_CONFIG.defaultBetas).toContain("interleaved-thinking-2025-05-14")
expect(CLAUDE_CODE_API_CONFIG.defaultBetas).toContain("fine-grained-tool-streaming-2025-05-14")
// Note: fine-grained-tool-streaming removed for OAuth compatibility
})
test("should have correct user agent", () => {
expect(CLAUDE_CODE_API_CONFIG.userAgent).toMatch(/^Roo-Code\/\d+\.\d+\.\d+$/)
// User-Agent must match Claude CLI format for OAuth tokens to be accepted
expect(CLAUDE_CODE_API_CONFIG.userAgent).toMatch(/^claude-cli\/\d+\.\d+\.\d+ \(external, cli\)$/)
})
})