erio
b6fa8b8eec
fix: update tests for defaultClientSecret and align migration 058
...
- Fix oauth_test.go and client_test.go to use defaultClientSecret
variable instead of env var (init() already sets the default)
- Align migration 058 gemini-3-pro-high/low/preview mappings with
constants.go (map to 3.1 versions)
2026-02-24 21:06:10 +08:00
shaw
e435a46db5
fix: 修复 antigravity UserAgent 重构遗留的编译错误和测试不匹配
...
- oauth.go: GetUserAgent() 缺少闭合大括号导致语法错误
- client_test.go/oauth_test.go: UserAgent 变量已重构为 GetUserAgent(),更新测试引用
- model_rate_limit_test.go: gemini-3-pro-preview 映射目标已更新为 gemini-3.1-pro-high,同步测试
2026-02-24 14:44:57 +08:00
yangjianbo
abf5de69fb
Merge branch 'main' into test
2026-02-12 23:43:47 +08:00
Edric Li
a4a46a8618
✨ feat(antigravity): 添加 onboardUser 支持并修复 project_id 补齐逻辑
...
- 新增 OnboardUser API 客户端方法,支持账号 onboarding 获取 project_id
- loadProjectIDWithRetry 增加 onboard 回退:LoadCodeAssist 未返回 project_id 时自动触发 onboarding
- GetAccessToken 中 project_id 补齐改用轻量 FillProjectID 替代全量 RefreshAccountToken
- 补齐逻辑增加 5 分钟冷却机制,防止频繁重试
- OnboardUser 轮询等待改为 context 感知,支持提前取消
- 提取 mergeCredentials 辅助方法消除重复代码
- 新增 extractProjectIDFromOnboardResponse 和 resolveDefaultTierID 单元测试
2026-02-11 13:41:55 +08:00
yangjianbo
fc8a39e0f5
test: 删除CI工作流,大幅提升后端单元测试覆盖率至50%+
...
删除因GitHub计费锁定而失败的CI工作流。
为6个核心Go源文件补充单元测试,全部达到50%以上覆盖率:
- response/response.go: 97.6%
- antigravity/oauth.go: 90.1%
- antigravity/client.go: 88.6% (新增27个HTTP客户端测试)
- geminicli/oauth.go: 91.8%
- service/oauth_service.go: 61.2%
- service/gemini_oauth_service.go: 51.9%
新增/增强8个测试文件,共计5600+行测试代码。
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-02-09 09:07:58 +08:00