chore: additional harness tests - #5155
Conversation
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 52 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThe provider harness adds Gemini ChangesProvider harness coverage
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
|
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Reviews (2): Last reviewed commit: "chore: additional harness tests" | Re-trigger Greptile |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
tests/e2e/api/collections/provider-harness.json (1)
37671-37674: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winCoverage gap:
gpt-5.2/gpt-5.5→xhighnormalization branch is untested.The section's own description states the normalization has three outcomes: gpt-5.6 passes
max/xhighthrough unchanged, gpt-5.2/5.5 downgrademaxtoxhigh, and other models downgrade tohigh. Only the first and third branches have test cases (lines 37675-37720 and 37721-37766); the gpt-5.2/5.5 →xhighbranch has no coverage at all, so a regression in that specific mapping would go undetected by this harness.Do you want me to add a test case for this branch? A minimal addition following the existing pattern:
{ "name": "openai/gpt-5.2 native /v1/responses reasoning.effort=max downgraded to xhigh - PR `#5130`", "request": { "method": "POST", "header": [{ "key": "Content-Type", "value": "application/json" }], "body": { "mode": "raw", "raw": "{\n \"model\": \"openai/gpt-5.2\",\n \"input\": \"Reply with the single word: ok\",\n \"reasoning\": {\n \"effort\": \"max\"\n },\n \"max_output_tokens\": 512\n}" }, "url": { "raw": "{{baseUrl}}/v1/responses", "host": ["{{baseUrl}}"], "path": ["v1", "responses"] } }, "event": [ { "listen": "test", "script": { "type": "text/javascript", "exec": [ "if ([401, 403, 429, 500, 502, 503, 504].indexOf(pm.response.code) !== -1) { return; }", "pm.test('gpt-5.2 effort max: 2xx', function () { pm.expect(pm.response.code, 'failed: ' + pm.response.text()).to.be.below(400); });", "if (pm.response.code >= 400) { return; }", "var r = pm.response.json();", "pm.test('gpt-5.2 effort max: normalized to xhigh', function () { pm.expect(r.reasoning, 'no reasoning echo').to.be.an('object'); pm.expect(r.reasoning.effort).to.eql('xhigh'); });" ] } } ] }Also applies to: 37721-37766
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@tests/e2e/api/collections/provider-harness.json` around lines 37671 - 37674, Add a test item to the existing “OpenAI Responses reasoning.effort max normalization” section covering model openai/gpt-5.2 with reasoning.effort set to max. Follow the neighboring response tests’ request and skip handling, then assert successful responses echo reasoning.effort as xhigh; preserve the existing gpt-5.6 and other-model cases.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@tests/e2e/api/collections/provider-harness.json`:
- Around line 37767-37812: Update the test script for “gpt-5.6
reasoning.context/mode” so it requires r.reasoning to be present and directly
asserts reasoning.context equals “current_turn” and reasoning.mode equals
“standard”; remove the conditional field guards while preserving the existing
response-status handling.
---
Nitpick comments:
In `@tests/e2e/api/collections/provider-harness.json`:
- Around line 37671-37674: Add a test item to the existing “OpenAI Responses
reasoning.effort max normalization” section covering model openai/gpt-5.2 with
reasoning.effort set to max. Follow the neighboring response tests’ request and
skip handling, then assert successful responses echo reasoning.effort as xhigh;
preserve the existing gpt-5.6 and other-model cases.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 41f991b3-2251-44b5-8534-866e8139bfb7
📒 Files selected for processing (2)
tests/e2e/api/HARNESS_COVERAGE_BACKLOG.mdtests/e2e/api/collections/provider-harness.json
Merge activity
|
The base branch was changed.
60a22fd to
c143166
Compare
c143166 to
4bf1bf6
Compare
## Summary Adds E2E harness test coverage for two recently merged PRs: Gemini `web_search_options` → `googleSearch` tool mapping with `url_citation` annotation passback (PR #5139), and OpenAI Responses API `reasoning.effort` normalization for `max`/`xhigh` values across GPT-5.x model variants (PR #5130). The backlog item for `web_search_options` is also marked as complete. ## Changes - Marks `web_search_options` as covered in `HARNESS_COVERAGE_BACKLOG.md` - Adds harness collection group **22** covering Gemini `web_search_options` → `googleSearch` translation, asserting that `url_citation` annotations are present in both non-streaming and SSE streaming responses (previously the option was silently dropped and no annotations were returned) - Adds harness collection group **23** covering `normalizeOpenAIReasoningEffort` behavior: - `gpt-5.6` passes `effort: "max"` through unchanged and the response echoes it back as `"max"` - `gpt-5` downgrades `effort: "max"` to `"high"` so the upstream does not return a 400 - `gpt-5.6` accepts and echoes `reasoning.context` and `reasoning.mode` fields that were previously stripped before serialization ## Type of change - [ ] Bug fix - [ ] Feature - [ ] Refactor - [ ] Documentation - [x] Chore/CI ## Affected areas - [ ] Core (Go) - [ ] Transports (HTTP) - [x] Providers/Integrations - [ ] Plugins - [ ] UI (React) - [ ] Docs ## How to test Import `tests/e2e/api/collections/provider-harness.json` into Postman or Newman and run groups 22 and 23 against a live environment with valid API keys for Gemini and OpenAI. ```sh newman run tests/e2e/api/collections/provider-harness.json \ --env-var baseUrl=<your-proxy-url> \ --folder "22. Gemini web_search_options → googleSearch (PR #5139)" \ --folder "23. OpenAI Responses reasoning.effort max normalization (PR #5130)" ``` Each test skips gracefully on 401/403/429/5xx so transient upstream errors do not cause false failures. A passing run confirms annotations are present for Gemini grounding responses and that `reasoning.effort` values are correctly normalized or passed through depending on the model. ## Screenshots/Recordings N/A ## Breaking changes - [x] No ## Related issues Closes coverage tracking for PR #5139 and PR #5130. ## Security considerations None. Tests only assert on response shape; no credentials are stored in the collection. ## Checklist - [ ] I read `docs/contributing/README.md` and followed the guidelines - [x] I added/updated tests where appropriate - [ ] I updated documentation where needed - [x] I verified builds succeed (Go and UI) - [ ] I verified the CI pipeline passes locally if applicable
## Summary Adds E2E harness test coverage for two recently merged PRs: Gemini `web_search_options` → `googleSearch` tool mapping with `url_citation` annotation passback (PR maximhq#5139), and OpenAI Responses API `reasoning.effort` normalization for `max`/`xhigh` values across GPT-5.x model variants (PR maximhq#5130). The backlog item for `web_search_options` is also marked as complete. ## Changes - Marks `web_search_options` as covered in `HARNESS_COVERAGE_BACKLOG.md` - Adds harness collection group **22** covering Gemini `web_search_options` → `googleSearch` translation, asserting that `url_citation` annotations are present in both non-streaming and SSE streaming responses (previously the option was silently dropped and no annotations were returned) - Adds harness collection group **23** covering `normalizeOpenAIReasoningEffort` behavior: - `gpt-5.6` passes `effort: "max"` through unchanged and the response echoes it back as `"max"` - `gpt-5` downgrades `effort: "max"` to `"high"` so the upstream does not return a 400 - `gpt-5.6` accepts and echoes `reasoning.context` and `reasoning.mode` fields that were previously stripped before serialization ## Type of change - [ ] Bug fix - [ ] Feature - [ ] Refactor - [ ] Documentation - [x] Chore/CI ## Affected areas - [ ] Core (Go) - [ ] Transports (HTTP) - [x] Providers/Integrations - [ ] Plugins - [ ] UI (React) - [ ] Docs ## How to test Import `tests/e2e/api/collections/provider-harness.json` into Postman or Newman and run groups 22 and 23 against a live environment with valid API keys for Gemini and OpenAI. ```sh newman run tests/e2e/api/collections/provider-harness.json \ --env-var baseUrl=<your-proxy-url> \ --folder "22. Gemini web_search_options → googleSearch (PR maximhq#5139)" \ --folder "23. OpenAI Responses reasoning.effort max normalization (PR maximhq#5130)" ``` Each test skips gracefully on 401/403/429/5xx so transient upstream errors do not cause false failures. A passing run confirms annotations are present for Gemini grounding responses and that `reasoning.effort` values are correctly normalized or passed through depending on the model. ## Screenshots/Recordings N/A ## Breaking changes - [x] No ## Related issues Closes coverage tracking for PR maximhq#5139 and PR maximhq#5130. ## Security considerations None. Tests only assert on response shape; no credentials are stored in the collection. ## Checklist - [ ] I read `docs/contributing/README.md` and followed the guidelines - [x] I added/updated tests where appropriate - [ ] I updated documentation where needed - [x] I verified builds succeed (Go and UI) - [ ] I verified the CI pipeline passes locally if applicable
## Summary Adds E2E harness test coverage for two recently merged PRs: Gemini `web_search_options` → `googleSearch` tool mapping with `url_citation` annotation passback (PR maximhq#5139), and OpenAI Responses API `reasoning.effort` normalization for `max`/`xhigh` values across GPT-5.x model variants (PR maximhq#5130). The backlog item for `web_search_options` is also marked as complete. ## Changes - Marks `web_search_options` as covered in `HARNESS_COVERAGE_BACKLOG.md` - Adds harness collection group **22** covering Gemini `web_search_options` → `googleSearch` translation, asserting that `url_citation` annotations are present in both non-streaming and SSE streaming responses (previously the option was silently dropped and no annotations were returned) - Adds harness collection group **23** covering `normalizeOpenAIReasoningEffort` behavior: - `gpt-5.6` passes `effort: "max"` through unchanged and the response echoes it back as `"max"` - `gpt-5` downgrades `effort: "max"` to `"high"` so the upstream does not return a 400 - `gpt-5.6` accepts and echoes `reasoning.context` and `reasoning.mode` fields that were previously stripped before serialization ## Type of change - [ ] Bug fix - [ ] Feature - [ ] Refactor - [ ] Documentation - [x] Chore/CI ## Affected areas - [ ] Core (Go) - [ ] Transports (HTTP) - [x] Providers/Integrations - [ ] Plugins - [ ] UI (React) - [ ] Docs ## How to test Import `tests/e2e/api/collections/provider-harness.json` into Postman or Newman and run groups 22 and 23 against a live environment with valid API keys for Gemini and OpenAI. ```sh newman run tests/e2e/api/collections/provider-harness.json \ --env-var baseUrl=<your-proxy-url> \ --folder "22. Gemini web_search_options → googleSearch (PR maximhq#5139)" \ --folder "23. OpenAI Responses reasoning.effort max normalization (PR maximhq#5130)" ``` Each test skips gracefully on 401/403/429/5xx so transient upstream errors do not cause false failures. A passing run confirms annotations are present for Gemini grounding responses and that `reasoning.effort` values are correctly normalized or passed through depending on the model. ## Screenshots/Recordings N/A ## Breaking changes - [x] No ## Related issues Closes coverage tracking for PR maximhq#5139 and PR maximhq#5130. ## Security considerations None. Tests only assert on response shape; no credentials are stored in the collection. ## Checklist - [ ] I read `docs/contributing/README.md` and followed the guidelines - [x] I added/updated tests where appropriate - [ ] I updated documentation where needed - [x] I verified builds succeed (Go and UI) - [ ] I verified the CI pipeline passes locally if applicable

Summary
Adds E2E harness test coverage for two recently merged PRs: Gemini
web_search_options→googleSearchtool mapping withurl_citationannotation passback (PR #5139), and OpenAI Responses APIreasoning.effortnormalization formax/xhighvalues across GPT-5.x model variants (PR #5130). The backlog item forweb_search_optionsis also marked as complete.Changes
web_search_optionsas covered inHARNESS_COVERAGE_BACKLOG.mdweb_search_options→googleSearchtranslation, asserting thaturl_citationannotations are present in both non-streaming and SSE streaming responses (previously the option was silently dropped and no annotations were returned)normalizeOpenAIReasoningEffortbehavior:gpt-5.6passeseffort: "max"through unchanged and the response echoes it back as"max"gpt-5downgradeseffort: "max"to"high"so the upstream does not return a 400gpt-5.6accepts and echoesreasoning.contextandreasoning.modefields that were previously stripped before serializationType of change
Affected areas
How to test
Import
tests/e2e/api/collections/provider-harness.jsoninto Postman or Newman and run groups 22 and 23 against a live environment with valid API keys for Gemini and OpenAI.Each test skips gracefully on 401/403/429/5xx so transient upstream errors do not cause false failures. A passing run confirms annotations are present for Gemini grounding responses and that
reasoning.effortvalues are correctly normalized or passed through depending on the model.Screenshots/Recordings
N/A
Breaking changes
Related issues
Closes coverage tracking for PR #5139 and PR #5130.
Security considerations
None. Tests only assert on response shape; no credentials are stored in the collection.
Checklist
docs/contributing/README.mdand followed the guidelines