Skip to content

test(e2e): make release fixtures sandbox-reachable - #6999

Merged
cv merged 1 commit into
mainfrom
codex/fix-v0.0.84-additional-e2e-fixtures
Jul 16, 2026
Merged

test(e2e): make release fixtures sandbox-reachable#6999
cv merged 1 commit into
mainfrom
codex/fix-v0.0.84-additional-e2e-fixtures

Conversation

@prekshivyas

@prekshivyas prekshivyas commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

Summary

Release-candidate E2E exposed two fixture endpoints that the OpenShell gateway could not reach, producing deterministic inference readiness HTTP 503 failures. This change gives the EXDEV fixture a real authenticated compatible endpoint and advertises both affected mocks through host.openshell.internal.

Changes

  • Start a real authenticated fake OpenAI-compatible server for openclaw-plugin-runtime-exdev instead of pointing onboarding at an intentionally dead port.
  • Bind the EXDEV and historical gateway-upgrade mocks on all runner interfaces and advertise their sandbox-reachable host address.
  • Preserve mock request logs as E2E artifacts for failure diagnosis.

Type of Change

  • Code change (feature, bug fix, or refactor)
  • Code change with doc updates
  • Doc only (prose changes, no code sample modifications)
  • Doc only (includes code sample changes)

Quality Gates

  • Tests added or updated for changed behavior
  • Existing tests cover changed behavior — justification:
  • Tests not applicable — justification:
  • Docs updated for user-facing behavior changes
  • Docs not applicable — justification: These changes only repair live E2E fixture reachability; production behavior, commands, configuration, and supported contracts are unchanged.
  • Sensitive paths changed (security, policy, credentials, preflight, onboarding, inference, runner, sandbox, or messaging)
  • Sensitive-path review completed or maintainer-approved waiver recorded — reviewer/approval link/justification:
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Verification

  • PR description includes a Signed-off-by: line and every commit appears as Verified in GitHub
  • Normal pre-commit, commit-msg, and pre-push hooks passed, or npm run check:diff passed when hooks were skipped or unavailable
  • Targeted behavior tests pass for the current change set, or tests are marked not applicable above — npx vitest run --project e2e-support test/e2e/support/device-auth-health-helpers.test.ts test/e2e/support/openshell-gateway-upgrade-workflow-boundary.test.ts test/e2e/support/openclaw-plugin-runtime-exdev-workflow-boundary.test.ts (3 files, 8 tests passed)
  • Applicable broad gate passed — npm test for broad runtime/test-harness changes; npm run check for repo-wide validation/coverage changes — command/result:
  • Quality Gates section completed with required justifications or waivers
  • No secrets, API keys, or credentials committed
  • npm run docs builds without warnings (doc changes only)
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Signed-off-by: Prekshi Vyas prekshiv@nvidia.com

Summary by CodeRabbit

  • Tests
    • Improved live deployment and upgrade test reliability by using a locally hosted, OpenAI-compatible mock service.
    • Updated test networking so the mock service is reachable through the expected environment endpoint.
    • Added artifact capture for mock service URLs and requests to support troubleshooting failed test runs.

@prekshivyas prekshivyas self-assigned this Jul 16, 2026
@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Live OpenShell E2E tests now use gateway-reachable fake OpenAI-compatible servers. The EXDEV test records server metadata and requests, cleans up the server, and uses its base URL; the upgrade test configures explicit host and public host values.

Changes

Gateway endpoint reachability

Layer / File(s) Summary
Fake endpoint setup
test/e2e/live/openclaw-plugin-runtime-exdev.test.ts, test/e2e/live/openshell-gateway-upgrade.test.ts
The live tests configure fake OpenAI-compatible servers for OpenShell reachability. The EXDEV test stores server artifacts, captures requests during cleanup, and uses fake.baseUrl; the upgrade test binds to 0.0.0.0 and exposes host.openshell.internal.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

  • NVIDIA/NemoClaw#6989: Updates live test fake-server binding and public host configuration for gateway access.
  • NVIDIA/NemoClaw#6994: Adds related fake endpoint wiring using gateway-reachable server configuration.

Suggested labels: area: e2e, area: sandbox, integration: openclaw, v0.0.84

Suggested reviewers: cv, jyaunches

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly reflects the main change: making E2E release fixtures reachable from the sandbox.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/fix-v0.0.84-additional-e2e-fixtures

Comment @coderabbitai help to get the list of available commands.

@github-code-quality

github-code-quality Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Code Coverage Overview

Languages: TypeScript

TypeScript / code-coverage/plugin

The overall coverage remains at 96%, unchanged from the main branch.

TypeScript / code-coverage/cli

The overall coverage in the codex/fix-v0.0.84-ad... branch remains at 80%, unchanged from the main branch.

Show a code coverage summary of the most impacted files.
File main e0729d7 codex/fix-v0.0.84-ad... c5d9e5a +/-
src/lib/securit...ntial-filter.ts 98% 99% +1%
src/lib/state/gateway.ts 91% 93% +2%

Updated July 16, 2026 06:00 UTC
Code Coverage is in Public Preview. Learn more and provide us with your feedback.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 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 `@test/e2e/live/openclaw-plugin-runtime-exdev.test.ts`:
- Around line 1021-1027: Update the fake server configuration in the test’s
startFakeOpenAiCompatibleServer call to set requireAuth to true, ensuring
authentication is enabled and the configured apiKey validates the
COMPATIBLE_API_KEY contract.
🪄 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: Enterprise

Run ID: 80fa653c-7882-4a4c-b250-d7eaff566342

📥 Commits

Reviewing files that changed from the base of the PR and between e0729d7 and c5d9e5a.

📒 Files selected for processing (2)
  • test/e2e/live/openclaw-plugin-runtime-exdev.test.ts
  • test/e2e/live/openshell-gateway-upgrade.test.ts

Comment on lines +1021 to +1027
const fake = await startFakeOpenAiCompatibleServer({
apiKey: "nemoclaw-exdev-dummy-key",
host: "0.0.0.0",
model: "nemoclaw-exdev-probe",
publicHost: "host.openshell.internal",
responseText: "ok",
});

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

Enable authentication on the fake server.

startFakeOpenAiCompatibleServer maps options.requireAuth to the server’s authentication flag. Supplying apiKey alone does not enable auth, so this test can pass without validating the configured COMPATIBLE_API_KEY contract. Add requireAuth: true.

Proposed fix
   const fake = await startFakeOpenAiCompatibleServer({
     apiKey: "nemoclaw-exdev-dummy-key",
+    requireAuth: true,
     host: "0.0.0.0",
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
const fake = await startFakeOpenAiCompatibleServer({
apiKey: "nemoclaw-exdev-dummy-key",
host: "0.0.0.0",
model: "nemoclaw-exdev-probe",
publicHost: "host.openshell.internal",
responseText: "ok",
});
const fake = await startFakeOpenAiCompatibleServer({
apiKey: "nemoclaw-exdev-dummy-key",
requireAuth: true,
host: "0.0.0.0",
model: "nemoclaw-exdev-probe",
publicHost: "host.openshell.internal",
responseText: "ok",
});
🤖 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 `@test/e2e/live/openclaw-plugin-runtime-exdev.test.ts` around lines 1021 -
1027, Update the fake server configuration in the test’s
startFakeOpenAiCompatibleServer call to set requireAuth to true, ensuring
authentication is enabled and the configured apiKey validates the
COMPATIBLE_API_KEY contract.

Source: Path instructions

@github-actions

github-actions Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor — Informational

Advisor assessment: Informational / high confidence
Next action: No advisor follow-up needed.
Findings: 0 blockers · 0 warnings · 0 suggestions
Status: No actionable findings remain in the canonical review ledger.

Model lanes

  • GPT-5.6 Terra (primary): Completed · high confidence · 0 blockers · 0 warnings · 0 suggestions
  • Nemotron 3 Ultra (second opinion): Completed · high confidence · 0 blockers · 0 warnings · 0 suggestions
  • Model comparison: normalized findings match; normalized E2E selections match; severity counts match.

Nemotron output stays in workflow artifacts and does not change the assessment above.

E2E guidance

Advisory only. E2E / PR Gate selects and runs jobs independently.

Recommended E2E: cloud-onboard, credential-sanitization, security-posture, openclaw-plugin-runtime-exdev, openshell-gateway-upgrade

Workflow run details

This automated review informs maintainers. Warnings and suggestions do not require a response. A maintainer decides whether to merge.

@cv
cv merged commit c1bda80 into main Jul 16, 2026
94 of 101 checks passed
@cv
cv deleted the codex/fix-v0.0.84-additional-e2e-fixtures branch July 16, 2026 06:13
@wscurran wscurran added area: ci CI workflows, checks, release automation, or GitHub Actions area: e2e End-to-end tests, nightly failures, or validation infrastructure bug-fix PR fixes a bug or regression labels Jul 29, 2026
@coderabbitai coderabbitai Bot mentioned this pull request Jul 30, 2026
23 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: ci CI workflows, checks, release automation, or GitHub Actions area: e2e End-to-end tests, nightly failures, or validation infrastructure bug-fix PR fixes a bug or regression

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants