Repository navigation
test(e2e): migrate shared-model and Ollama live happy paths to HCL E2E - #14090
Merged
Merged
Conversation
Add two Live / HCL GPU scenarios: OpenClaw and Hermes sharing one vLLM model with bearer authentication, and OpenClaw on hosted inference beside Hermes on a managed Ollama model. They are the integration cases docker-vllm-shared-two-agents and docker-hosted-ollama-two-agents with the GPU runner's hardware profile and the candidate agent images. Delete the Rust tests whose happy paths they cover: the Spark plan and apply test, shared_service, managed_ollama, existing_ollama, and the read-only retained-state tests managed.rs and nemoclaw-sdk's managed_live, which duplicate the scenarios' unchanged plan and destroy. Remove the service-image helpers only those tests used. The Spark image-change test stays in tests/e2e/rust. Refs #14061
Collaborator
Author
Authoring session — opening
|
This was referenced Nov 2, 2026
cv
pushed a commit
that referenced
this pull request
Nov 3, 2026
## Failure v1 live coverage was spread across separate Rust lifecycles that each repeated the same apply, invoke, reapply, and destroy code with their own state readers: `brev.rs` (its own test executable), `fabric_live.rs`, `model_live.rs`, `dummy_agent.rs`, and `hosted_parity`'s live module. Only Brev and the dummy test ran in CI; the others were manual. The HCL E2E pattern from #13723 covered two cases, and the CLI applied each deployment before `tofu test` started. ## Decision Part of #14061 (parent #13933). Builds on #14088, now merged into `v1`; this branch also contains #14090, which was merged into it. Each scenario is a `cases/<case>.yaml` document and a `tests/e2e/hcl/tests/<case>.tftest.hcl` with four runs: 1. `apply` through the bundled CLI. 2. A real reply from the recorded runtime after the apply process exited, with an exact answer when the case names one. 3. A `plan` with no changes. 4. `destroy` that retains only the case's persistent storage. | Case | Runner | Replaces | |---|---|---| | `docker-openclaw-nvidia` | Live / HCL | The existing reply check, now also applying, planning, and destroying in HCL | | `docker-openclaw-v0-parity` (moved from `fixtures/openclaw-nvidia-hosted/v1.yaml`) | Live / HCL, Live / Brev | `brev.rs`, `fabric_live.rs`, `hosted_parity` OpenClaw live | | `docker-hermes-v0-parity` (moved from `fixtures/hermes-nvidia-hosted/v1.yaml`) | Live / HCL | `hosted_parity` Hermes live | | `docker-openclaw-vllm` | Live / HCL GPU runner | `model_live.rs` | | `docker-dummy` | `cargo ci live-docker` | `dummy_agent.rs` | | `docker-openclaw-hermes-vllm` (#14090) | Live / HCL GPU runner | `spark` plan-and-apply test, `shared_service` | | `docker-openclaw-hermes-ollama` (#14090) | Live / HCL GPU runner | `managed_ollama`, `existing_ollama` | Layout of the `e2e` test tree: - `tests/e2e/hcl/`: the HCL E2E scenarios and their modules, run by `hcl_live::case`. - `tests/e2e/rust/`: live tests not yet migrated, with their fixtures and helpers, moved unchanged except for relative include paths. Module names are unchanged, so test names and the `live-docker` and `live-kind` filters still match. - `hcl_live.rs` and `hosted_parity.rs` stay at the top: the HCL runner, and the deterministic v0 comparisons of the parity cases. Components: - `tests/e2e/hcl/cli` runs one bundled `nemoclaw` command (`plan`, `apply`, `destroy`) and returns its exit status, error, and JSON result. `hcl_live::case` no longer applies. - `tests/e2e/hcl/verifier` gains an optional exact `answer`. The probe writes reply text to the run's private `work` directory; published reports still hold outcomes only. - `cargo ci live-docker` binds the dummy case's template to a fresh UID, port, subnet, and image (`bind_case`) and passes the copy as `NEMOCLAW_HCL_DOCUMENT`. Its labelled-resource cleanup is unchanged. - Live / HCL builds the Hermes image and binds `nc-fabric-hermes@sha256:0…`. Brev runs the `e2e` executable's `hcl_live::case` (the separate `brev` test target is removed), then `nemoclaw destroy`, and uploads the reports, destroy receipt, and fresh-host checks; deleting the VM remains the required cleanup. - `hosted_parity`'s deterministic v0 comparisons read the moved case documents. Removed checks that were not on the successful path, and their owners: | Removed check | Owner | |---|---| | Export equals the document; reapplying it changes nothing | The SDK/CLI export test #14063 keeps | | Runtime and resource identities unchanged by reapply; restart of a stopped agent runtime in the same sandbox | #14063 `kubernetes-external-three-agents` | | Exact created resources; plan matches apply; `plan --destroy` preview | #14063 graph scenarios | | Undeclared egress denied | Policy sent to OpenShell: HCL integration `docker-openclaw-nvidia`. Enforcement is OpenShell's. | | First plan leaves Docker unchanged | Proposed: #14064 `openshell/gateway` plan contract; not yet confirmed | | vLLM manifest, storage reuse, `USR1` memory guard, recovery of the stopped container | Proposed: #14064 `nemoclaw/runtime` and `nemoclaw/storage`, and the vLLM supervisor tests; not yet confirmed for the stopped-container recovery | | Workspace file kept across reapply | Redundant with the unchanged plan | | Dummy: no sandbox objects after destroy | `cargo ci live-docker` cleanup fails on leftovers | | Dummy: derived image's executable in the sandbox | Dropped; the image is still built and deployed | | `fabric_live` against an external gateway | Was manual only; no CI case before or after | Not in this PR: `spark.rs`, `managed_gateway.rs`, `interfaces_live.rs`, `cache_provider.rs`, `docker_registry.rs`, the Kind suite, `service_images`, and the read-only SDK and provider live tests. Their happy paths and failure owners are a follow-up under #14061. OpenTofu 1.12.9 limits found here (also in #14063): assertions cannot read `run.<name>`, and a run's outputs become unknown once a later run applies the same module. The scenarios avoid both. Net against `v1`, including #14090: +1,114/−2,583 across 63 files, many of them renames into `tests/e2e/rust`. #14090 also deleted `managed.rs` and `nemoclaw-sdk`'s `managed_live`, which only re-read an earlier run's state. ## Validation - After merging `v1` (the squashed #14088, #14064, and #14080): `cargo ci fmt`, `cargo ci clippy`, and `cargo ci test` (1,746 tests) passed on darwin_arm64. The merge keeps this branch's `tests/e2e/hcl` and `tests/e2e/rust` layout; every other file matches `v1`. - After merging #14088's branch and adding `tests/e2e/rust`: `cargo ci fmt`, `cargo ci clippy`, and `cargo ci test` (1,746 tests) passed on darwin_arm64. The Linux-only modules (`docker_registry`, `service_images`, and the Ollama tests) don't compile on macOS; I checked that each of their moved include paths names an existing file, and Linux CI compiles them. One run hit `release_assessment::scanner::tests::subprocess_failures_hide_stderr_and_timeouts_reap_the_owned_process` under load; it passed three isolated reruns and the next full run. - `hcl_live::case`, `hosted_parity::`, `hcl_integration::every_scenario_test_names_a_case`, `live_docker::tests::the_dummy_case_binds_its_identity_gateway_and_image`, and the two `ci_lifecycle::live_docker_*` tests pass. - Every scenario passes under OpenTofu 1.12.9 with a fake `nemoclaw` and probe. A wrong answer and a failed apply each fail the expected run. - `tofu fmt -check`, `shellcheck` on the Brev scripts, and `tools/ci/test_brev*.py` pass. - Deferred to CI: `cargo ci live-docker` runs `docker-dummy` on this PR. Not run: Live / HCL (four cases, including the GPU lane) and Live / Brev need a push to `run-hcl-e2e/**` or `run-brev-v1-e2e/**`. Run them before merge; the deleted Rust live tests have no live replacement evidence until they pass. `cargo ci lifecycle` was not run locally.
cv
pushed a commit
that referenced
this pull request
Nov 5, 2026
## Failure `tests/e2e/rust/interfaces_live.rs` (806 lines, plus `pseudo_terminal.rs`) checked OpenClaw's, Hermes's, and Deep Agents Code's interfaces through a model stand-in in the test process, mixing the successful path with refusal, recovery, and leak checks. #14061 item 1 moves the successful path to HCL E2E with real inference. ## Decision Closes #14061 (parent #13933). Stacked on #14178 (#14176, #14174). Follows the maintainer's item 1 decision. - **New case `docker-openclaw-hermes-interfaces`** in `cargo ci live-docker`, on a stub model (review by @cv): OpenClaw with its Control UI on 18789; Hermes with its API server on 8642 and dashboard on 9119. A new `tests/e2e/hcl/model` module runs the stub with the bundled Docker provider: the pinned `nginx-unprivileged` image on the host network at the case's model port, listing one model, answering every chat completion with one reply (streamed when asked), and refusing any request without the run's key. - **New `tests/e2e/hcl/interface` module and `hcl_live::interface` probe**: per request, read the reported token with `openshell sandbox exec`, forward the port with `openshell forward service`, send one request with the token as a Bearer credential. Reports hold status codes; tokens and bodies stay in the private `work` directory; the module outputs only failing target names. - **Scenario:** apply must report the three interfaces with their ports, sign-in, and token files; the Control UI page loads and its configuration accepts the token; Hermes's API lists models and answers with the stub's reply, which also shows NemoClaw sent the configured key; Hermes's dashboard page loads with its session token; destroy keeps only gateway storage. - **`cargo ci live-docker`:** installs the pinned OpenShell CLI again, binds the case (UID, gateway port and subnet, stub address, OpenClaw and Hermes images, a fresh model key), and runs each HCL case (`docker-dummy`, this one) as its own nextest command. Its wall limit is raised to 480 s until a few runs measure the new total. - **Deleted:** `interfaces_live.rs`, `pseudo_terminal.rs`, `live::interfaces_document` and its test. `tests/e2e/rust/` is now empty. | Rust check | New owner | |---|---| | Apply reports ports, token paths, sign-in | Scenario `apply` assertion | | OpenClaw Control UI loads; configuration accepts the token | `interfaces` run | | Hermes API accepts its token and answers a chat completion | `interfaces` run, with the stub's reply | | Hermes dashboard page loads with its session token | `interfaces` run | | Missing or wrong tokens refused; dashboard killed; tokens kept out of output and state; undeclared interface rejected at plan | #14060 integration items | | Deep Agents Code terminal; Hermes browser chat (pseudo-terminal) | Dropped (maintainer decision) | | Every model request carried the configured key | The stub refuses any request without the run's key | **Fixes for the first Live / HCL run of every migrated case** (run 41804342269 and 41833590603; all other cases passed, including this PR's new one): - `hcl/cli` now reports the CLI's error message. With `--output json`, the CLI writes a failed command's redacted message in its JSON on standard output, so failed applies showed an empty message. - `docker-hermes-v0-parity` (#14082) failed at plan: the current Hermes adapter requires read access to `/opt/nemo-relay/plugins/switchyard`, which the v0 export's explicit filesystem policy predates. The case grants it, and `hosted_parity`'s projection adds it like the v1 images' user and group. - `docker-openclaw-hermes-vllm` (#14090) failed at Hermes's start: Qwen3-4B's 40,960-token window is below the 64,000 tokens Hermes requires, as `docs/inference.md` states. The case is now `docker-openclaw-vllm-shared`, two OpenClaw agents sharing the model; `docker-openclaw-hermes-ollama` keeps Hermes on a managed model. Not done here: `cargo ci live-docker` still builds the Deep Agents Code image, which nothing in that suite uses now; removing it touches the live image publishing lists and is left as a follow-up. Net: +393 / −1,270 across 17 files. ## Validation - Local (macOS): `cargo ci fmt`, `cargo ci test` (1,753 tests), `cargo clippy --all-targets --all-features` for `nemoclaw-e2e` and `nemoclaw-build` pass. - The scenario passes against a fake CLI and probe, and fails naming `api_chat` when the reply is not `FOUR`. - Live: the `docker-openclaw-hermes-interfaces` lane runs on a `run-hcl-e2e/**` push of this branch. Refs #14061
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Failure
Part of #14061 (parent #13933). Stacked on #14082, which is stacked on #14088.
The live checks for several agents sharing one local model, and for agents on a managed Ollama model, were Rust tests that no workflow ran: the Spark plan-and-apply test needs GB10 hardware, and
shared_service,managed_ollama, andexisting_ollamarun against a simulated Ollama service. Two more,managed.rsandnemoclaw-sdk'smanaged_live, only re-read state an earlier manual run left behind.Decision
Add two HCL E2E scenarios on the Live / HCL NVIDIA GPU runner. Each has the four runs from #14082: apply through the bundled CLI, a reply from each agent's recorded runtime, a plan without changes, and destroy that keeps only the expected storage.
docker-openclaw-hermes-vllmdocker-openclaw-hermes-ollamaqwen3:0.6bFOUR; Hermes any replyBoth documents copy the integration cases
docker-vllm-shared-two-agentsanddocker-hosted-ollama-two-agents, changing only what the GPU runner needs: thertx-pro-6000-blackwellhardware profile, candidate agent image templates, and their own identity, port, and subnet. I first changed the shared cases instead, but the profile and image changes alter resource addresses that the #14063 integration scenarios assert, sohcl_integrationfailed; the shared cases are unchanged here.Live / HCL builds the
ollamaimage for the Ollama case and bindsnc-prototype-ollama@sha256:a…to it, as it binds the vLLM and agent images.Deleted, with where each remaining check belongs:
spark::spark_yaml_plans_and_applies_expected_resourcesdocker-openclaw-hermes-vllmtests/e2e/rust/spark.rs.shared_servicedocker-openclaw-hermes-vllmmanaged_ollamadocker-openclaw-hermes-ollamanemoclaw/storageexisting_ollamadocker-openclaw-hermes-ollama(managed Ollama)managed.rs,nemoclaw-sdkmanaged_liveThe service-image helpers that only those tests used are removed;
remote_modelskeeps the rest.Net: +354/−641 across 16 files.
Validation
cargo ci fmt,cargo ci clippy, andcargo ci test(1,746 tests) passed on darwin_arm64.cargo ci lifecycleon darwin_arm64:hcl_integrationshards pass with the shared cases unchanged. One run failednemoclaw-providerservice_readiness::standalone_readiness_defers_to_apply_rechecks_unchanged_services_and_allows_destroyunder load; it passed twice when run alone, and this PR doesn't touch providers.-D warningsafter stripping theircfg(target_os = "linux")gates in a scratch copy, which found the helpers removed here; the files in the PR keep their gates.run-hcl-e2e/**, which hasn't been authorized. Until they pass, this PR should not merge.