test(e2e): migrate test-diagnostics.sh to vitest - #5347
Conversation
Reserve Phase 4 E2E migration work for test-diagnostics.sh. Refs #5098
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (3)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughAdds a new Changesdiagnostics-vitest E2E scenario
Sequence Diagram(s)The live diagnostics test orchestrates several sequential phases of CLI execution and verification (shown in the hidden review stack layer diagram above): version checking, debug archive creation in quick and full modes, secret-leak scanning via extraction, sandbox-specific debug acceptance/rejection flows, sandbox configuration inspection, and credentials list/reset validation. This multi-phase flow is visualized in the "Live diagnostics test flow" diagram within the test body layer. Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
E2E Advisor RecommendationRequired E2E: Dispatch hint: Full advisor summaryE2E Recommendation AdvisorBase: Required E2E
Optional E2E
New E2E recommendations
Dispatch hint
|
Vitest E2E Scenario RecommendationRequired Vitest E2E scenarios: Dispatch required Vitest E2E scenarios:
Full Vitest E2E advisor summaryVitest E2E Scenario AdvisorBase: Required Vitest E2E scenarios
Optional Vitest E2E scenarios
Relevant changed files
|
PR Review AdvisorFindings: 0 needs attention, 2 worth checking, 0 nice ideas Review findings🛠️ Needs attention
🔎 Worth checking
🌱 Nice ideas
Consider writing more tests for
Since last review detailsCurrent findings:
This is an automated advisory review. A human maintainer must make the final merge decision. |
Vitest E2E Scenario Results — ❌ Some jobs failedRun: 27438057992
|
Vitest E2E Scenario Results — ❌ Some jobs failedRun: 27445950567
|
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27447165043
|
# Conflicts: # tools/e2e-scenarios/free-standing-jobs.env
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27448996355
|
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27451481008
|
# Conflicts: # tools/e2e-scenarios/free-standing-jobs.env
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27452009591
|
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27452769626
|
Code Coverage OverviewLanguages: TypeScript TypeScript / code-coverage/pluginThe overall coverage in the Show a code coverage summary of the most covered files.
TypeScript / code-coverage/cliThe overall coverage in the Show a code coverage summary of the most covered files.
Updated |
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27462517963
|
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27463570996
|
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27464207573
|
Vitest E2E Scenario Results — ✅ All jobs passedRun: 27594970645
|
…nostics Signed-off-by: Carlos Villela <cvillela@nvidia.com>
There was a problem hiding this comment.
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 @.github/workflows/e2e-vitest-scenarios.yaml:
- Line 1990: The custom GPU runner label `linux-amd64-gpu-rtxpro6000-latest-1`
used in the `runs-on` field is not recognized by actionlint, causing workflow
linting to fail. Either add this custom runner label to the runner-label
configuration in the actionlint.yaml file, or update the `runs-on` value to use
your repository's standard self-hosted label syntax so that actionlint can
validate the workflow correctly.
🪄 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: 63948d1f-4e57-402a-a615-cb551d0caa1e
📒 Files selected for processing (3)
.github/workflows/e2e-vitest-scenarios.yamltest/e2e-scenario/support-tests/e2e-scenarios-workflow.test.tstools/e2e-scenarios/workflow-boundary.mts
🚧 Files skipped from review as they are similar to previous changes (2)
- test/e2e-scenario/support-tests/e2e-scenarios-workflow.test.ts
- tools/e2e-scenarios/workflow-boundary.mts
There was a problem hiding this comment.
Caution
Inline review comments failed to post. This is likely due to GitHub's internal server error or limits when posting large numbers of comments. If you are seeing this consistently it is likely a permissions issue. Please check "Moderation" -> "Code review limits" under your organization settings.
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 @.github/workflows/e2e-vitest-scenarios.yaml:
- Line 1990: The custom GPU runner label `linux-amd64-gpu-rtxpro6000-latest-1`
used in the `runs-on` field is not recognized by actionlint, causing workflow
linting to fail. Either add this custom runner label to the runner-label
configuration in the actionlint.yaml file, or update the `runs-on` value to use
your repository's standard self-hosted label syntax so that actionlint can
validate the workflow correctly.
🪄 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: 63948d1f-4e57-402a-a615-cb551d0caa1e
📒 Files selected for processing (3)
.github/workflows/e2e-vitest-scenarios.yamltest/e2e-scenario/support-tests/e2e-scenarios-workflow.test.tstools/e2e-scenarios/workflow-boundary.mts
🚧 Files skipped from review as they are similar to previous changes (2)
- test/e2e-scenario/support-tests/e2e-scenarios-workflow.test.ts
- tools/e2e-scenarios/workflow-boundary.mts
🛑 Comments failed to post (1)
.github/workflows/e2e-vitest-scenarios.yaml (1)
1990-1990:
⚠️ Potential issue | 🟠 Major | ⚡ Quick winDeclare the custom GPU runner label in actionlint config (or use self-hosted label syntax).
Line 1990 introduces
runs-on: linux-amd64-gpu-rtxpro6000-latest-1, and actionlint currently flags it as unknown. If this is a self-hosted label, add it toactionlint.yamlrunner-label configuration (or switch to the repo’s accepted self-hostedruns-onform) so workflow linting does not fail.🧰 Tools
🪛 actionlint (1.7.12)
[error] 1990-1990: label "linux-amd64-gpu-rtxpro6000-latest-1" is unknown. available labels are "windows-latest", "windows-latest-8-cores", "windows-2025", "windows-2025-vs2026", "windows-2022", "windows-11-arm", "ubuntu-slim", "ubuntu-latest", "ubuntu-latest-4-cores", "ubuntu-latest-8-cores", "ubuntu-latest-16-cores", "ubuntu-24.04", "ubuntu-24.04-arm", "ubuntu-22.04", "ubuntu-22.04-arm", "macos-latest", "macos-latest-xlarge", "macos-latest-large", "macos-26-intel", "macos-26-xlarge", "macos-26-large", "macos-26", "macos-15-intel", "macos-15-xlarge", "macos-15-large", "macos-15", "macos-14-xlarge", "macos-14-large", "macos-14", "self-hosted", "x64", "arm", "arm64", "linux", "macos", "windows". if it is a custom label for self-hosted runner, set list of labels in actionlint.yaml config file
(runner-label)
🤖 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 @.github/workflows/e2e-vitest-scenarios.yaml at line 1990, The custom GPU runner label `linux-amd64-gpu-rtxpro6000-latest-1` used in the `runs-on` field is not recognized by actionlint, causing workflow linting to fail. Either add this custom runner label to the runner-label configuration in the actionlint.yaml file, or update the `runs-on` value to use your repository's standard self-hosted label syntax so that actionlint can validate the workflow correctly.Source: Linters/SAST tools
Summary
Migrate
test/e2e/test-diagnostics.shwith the simplest equivalent live Vitest coverage.Legacy shell deletion and nightly shell lane retirement are deferred to #5098 Phase 11; this PR adds the replacement Vitest path beside the stable legacy lane.
Related Issues
Refs #5098
Contract mapping
nemoclaw --versionexits 0 and prints semver.test/e2e-scenario/live/diagnostics.test.tsruns the repo CLI entrypoint and asserts semver output.nemoclaw debug --quick --outputcreates a non-empty archive within the quick timeout.debug --quick --outputand checks archive existence/size/time.nemoclaw debug --outputcreates an extractable tarball with no NVIDIA credential leaks.nvapi-*patterns.tar, archive extraction, credential scanning.--sandboxsucceeds while unknown--sandboxfails, names the sandbox, reportsnot registered, and writes no partial tarball.openclaw.jsonis readable and host status shows model/provider diagnostics.nemoclaw <sandbox> status.credentials listhides values andcredentials resetremoves the provider credential.nvidia-prodwhen present.Simplicity check
nightly-e2e.yamljobdiagnostics-e2eviae2e-script.yaml, defaultubuntu-latest, Docker/OpenShell,NVIDIA_API_KEY,NEMOCLAW_RECREATE_SANDBOX=1, 45-minute reusable timeout.ubuntu-latestrunner class with Docker/OpenShell andNVIDIA_API_KEYine2e-vitest-scenarios.yamljobdiagnostics-vitest.diagnostics.test.ts.e2e-vitest-scenarios.yamlwithjobs=diagnostics-vitestorscenarios=diagnostics.Verification
npm ci --ignore-scriptsnpm run build:clinpm run typecheck:cliNEMOCLAW_RUN_E2E_SCENARIOS=1 npx vitest run test/e2e-scenario/live/diagnostics.test.ts --project e2e-scenarios-live(local no-secret run skips with evidence)npx vitest run test/e2e-scenario/support-tests/e2e-scenarios-workflow.test.ts --project e2e-vitest-supportgit diff --checkorigin/main; support workflow test re-ran locally after refresh.workflow_dispatch,jobs=diagnostics-vitest) — passedSummary by CodeRabbit
Tests
Chores