Skip to content

test: run the SSH simulator's tests on Windows - #12963

Merged
cv merged 3 commits into
v1from
test/windows-ssh-simulator
Oct 10, 2026
Merged

cv merged 3 commits into
v1from
test/windows-ssh-simulator

Conversation

@cv

@cv cv commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator

Part of #12943 and #12876.

Failure

remote_service, service_capacity, and service_readiness were Unix-only. They installed nemoclaw-e2e's simulated ssh as a symlink or a /bin/sh wrapper, and joined PATH with a colon. The simulator itself uses only portable APIs.

Decision

  • install_ssh_simulator: copies the simulator as ssh and writes a file beside it that names its state directory. OpenTofu passes its providers only platform variables, so the simulator reads that file when NEMOCLAW_TEST_REMOTE is absent. This replaces remote_service's shell wrapper.
  • path_with: puts the simulator first on PATH, joined with the platform separator.
  • Shared relay: the fake engine relay moves into nemoclaw_test_fixtures::ssh. On Windows the simulator and the relay both answer as ssh, and the simulator shadowed the relay on PATH, so image discovery reached the simulator and found no runtime metadata. The simulator now relays any command that dials a loopback fixture engine, and simulates the rest.
  • Capacity and readiness: these tests install the simulator beside their providers. That replaces the relay TofuWorkspace puts there, which Windows finds before PATH.
  • Ungated: all three modules now run on every platform.
  • Windows partitions: the Windows lifecycle suite runs in two partitions, as Linux does.

Validation

  • Linux, OpenTofu tests: service_capacity and service_readiness pass through OpenTofu.
  • Linux, remote_service sample: I ran three of its tests (the Pi admission test and two partial-failure tests) against a rebuilt bundle; all pass.
  • Lint: clippy at -D warnings and fmt are clean.
  • Windows: in this PR's CI (run), the Windows lifecycle step ran 108 tests and all passed, against 97 on v1. In one partition that took 414 s wall. With two partitions (run), they run 60 and 48 tests in 278 s and 227 s, all passing.

remote_service, service_capacity, and service_readiness were Unix-only
because they installed nemoclaw-e2e's simulated ssh as a symlink or a
shell wrapper, and joined PATH with a colon. The simulator itself uses
only portable APIs.

install_ssh_simulator now copies it as ssh beside a file naming its
state directory, which the simulator reads when OpenTofu does not pass
NEMOCLAW_TEST_REMOTE on; this replaces remote_service's shell wrapper.
path_with builds PATH with the platform separator.

Part of #12943.
@cv cv added area: ci CI workflows, checks, release automation, or GitHub Actions v1 NemoClaw v1 branch labels Oct 10, 2026
@github-actions

Copy link
Copy Markdown
Contributor

cv added 2 commits October 10, 2026 02:44
On Windows the SSH simulator and the fake engine relay both answer as
ssh, and the simulator shadowed the relay on PATH, so image discovery
reached the simulator and found no runtime metadata. Providers launched
from a TofuWorkspace found the relay beside them first, so they never
reached the simulator.

The relay moves into nemoclaw_test_fixtures::ssh, and the simulator
relays commands that dial a loopback fixture engine before simulating
the rest. The capacity and readiness tests install the simulator beside
their providers, replacing the relay there.
Windows now runs 108 lifecycle tests, 414 s in one partition; two
partitions halve its wall time, as on Linux.
@cv
cv merged commit e2a70c0 into v1 Oct 10, 2026
@cv
cv deleted the test/windows-ssh-simulator branch October 10, 2026 10:51
cv added a commit that referenced this pull request Oct 10, 2026
## Failure

Live / Docker and Live / Kind were separate workflows. A workflow run
can't use another run's artifacts or `needs:` another run's jobs, so
each live job built its own bundle, which took 416–551 s on #12956. That
duplicated CI / Native's `Build bundle` job for the same commit. Across
the last 15 PRs merged into `v1`, these were the slowest workflows, with
medians of 22.2 and 21.3 minutes.

## Decision

Run the live suites as `Live / Docker` and `Live / Kind` jobs in
`native-platform.yml`. Their steps live in a shared composite action,
`.github/actions/live-suite`. Only the two Linux platforms enable them,
through a new `live` input; other platforms show them as skipped.

- **Shared bundle:** each job `needs:` only that platform's `Build
bundle`. It downloads and unpacks the bundle instead of building one,
then builds its test executables from the dependency cache and runs
`cargo ci live-docker` or `cargo ci live-kind`.
- **Not required:** each live job uses `continue-on-error: true`, so a
live failure shows on its job without failing the platform's required
`Test / PLATFORM` check. A throwaway workflow on an orphan branch, since
deleted, confirmed that a reusable workflow still reports success to its
caller in this case.
- **Relevance:** each job still runs `nemoclaw-build changes live` and
skips its remaining steps for changes that can't affect the suite.
`.config/determinator-live.toml` now treats `native-platform.yml` and
`rust.yml`, which hold the live jobs, as live inputs.
- **Triggers:** CI / Native now also runs on `run-live/**` branch
pushes, which replace the `run-live-docker/` and `run-live-kind/`
prefixes. The live jobs follow Native's concurrency: superseded PR runs
are cancelled, and `v1` pushes finish.
- **Docs:** `testing.md` describes the combined jobs. It also no longer
says Windows runs its lifecycle suite on one runner; #12963 gave every
platform two partitions.
- **Removed:** `live-docker.yml` and `live-kind.yml`. The jobs now
appear as `linux_arm64 / Live / Docker`, `linux_amd64 / Live / Kind`,
and so on.

Expected effect: on a warm run, the bundle is ready after about 4–7
minutes, so live results should arrive in about 12–17 minutes instead of
21–22, with four fewer bundle builds per run. That's an estimate; this
PR's own run shows the first measurement.

## Validation

- The live relevance test now requires changes to `native-platform.yml`
and `rust.yml` to run the suites. It failed against the old rules and
passes; all 8 relevance tests pass.
- `actionlint` passes on every workflow, and `fern check` passes.
- `cargo ci` passed: 1,324 workspace tests and all 121 lifecycle tests.
- Stacked PRs don't get CI / Native, so `run-live/live-in-native` branch
pushes ran it instead. Both runs passed every job, and the second ([run
38043908247](https://github.com/NVIDIA/NemoClaw/actions/runs/38043908247))
used the named jobs. Each live job started as soon as its platform's
bundle finished, and none built a bundle of its own. Branch pushes can't
restore `v1`'s caches, so both runs built cold; this PR's run after
retargeting to `v1` shows warm timings.
cv added a commit that referenced this pull request Oct 10, 2026
## Failure

Since #12963, Windows runs many more lifecycle tests, and Windows again
sets how long required checks take. In warm run
[38047731956](https://github.com/NVIDIA/NemoClaw/actions/runs/38047731956):

- **Windows `Build bundle`** finished at 525 s, and its two lifecycle
shards then took 252 s and 312 s. Required checks were done at about 839
s.
- **Other platforms** were done earlier: macOS at 583 s and Linux at 495
s.
- **Shard contents:** 60 and 48 tests, with 805 s and 656 s of summed
test time across four slots each. The longest single test,
`remote_service::managed_bearer_credentials_survive_export_reapply_and_destroy`,
takes 172 s.

## Decision

Give Windows three lifecycle partitions. Each shard then holds about 490
s of summed test time, about 120 s per slot, though the 172-second test
still sets a floor for its shard. Expected saving: about 1.5 minutes on
Windows' path, for one more Windows job.

The partition count comes from the matrix size, so no other change is
needed. `testing.md` now says Windows runs three partitions.

## Validation

- `actionlint` passes.
- `cargo ci` passed.
- This PR's own run shows the Windows shard times.
cv added a commit that referenced this pull request Oct 10, 2026
…12967)

Part of #12876; closes #12879's remaining `ELSEWHERE` entries and
advances #12878.

## Failure

The nemoclaw provider's contract binary listed five types in
`ELSEWHERE`, tested only in nemoclaw-e2e:

- `managed_gateway`, `service_capacity`, and `service_readiness` tests
needed nemoclaw-e2e's fixture provider and SSH simulator. Cargo sets
`CARGO_BIN_EXE_*` only for a package's own tests, so the provider crate
could not use them.
- `gateway_storage` had no test without real Docker.
- `inference_capabilities` was listed as tested only through SDK
deployments, but nemoclaw-e2e already had an authored-HCL test for it.

## Decision

- **Shared fixture executables.** `terraform-provider-nemoclaw-fixture`
and `nemoclaw-e2e-ssh-fixture` move into nemoclaw-test-fixtures as
`nemoclaw-fixture-provider` and `nemoclaw-fixture-ssh-simulator`.
`fixture_executable(name)` finds them in the parent of the test
executable's `deps` directory. That is where Cargo writes binaries and
where nextest extracts archived non-test binaries. Because the lifecycle
filter already selects nemoclaw-test-fixtures' `ssh_relay` binary,
archives include both new executables. I confirmed this with `nextest
archive`. `ssh::install_simulator` and `path_with` replace
nemoclaw-e2e's helpers. The simulator still relays loopback fixture
engines on Windows (#12963).
- **Moved tests.** `provider_protocol`, `service_capacity`, and
`service_readiness` move without changes to their assertions.
remote_service and service_images in nemoclaw-e2e now get the simulator
from nemoclaw-test-fixtures.
- **`inference_capabilities`.** The authored-HCL test moves from
nemoclaw-e2e. New cases cover an Anthropic catalog that rejects the
request without a credential (`unavailable`, authentication `required`,
no upstream text) and invalid inputs that fail validation without
contacting the endpoint. The SDK-deployment test stays in nemoclaw-e2e.
- **`gateway_storage`.** A new test uses a stateful fake Docker engine
that stores volumes, networks, containers, and archive uploads. It
checks:
  - validation of an invalid generation
  - a plan that changes nothing on the engine
- one initialization: network, volume, initializer, key, and
`gateway.toml`
  - the `data_path` output
  - an unchanged plan
- refresh failures that keep state for configuration drift and a missing
volume
  - a destroy that is refused while state is kept
  
Managed gateway resources accept only a local engine socket, so this
module is `#[cfg(unix)]` with a comment, like the existing
managed-gateway test.
- `ELSEWHERE` is now empty. The coverage test still enforces it.
- Cost: nemoclaw-test-fixtures now depends on nemoclaw-sdk,
nemoclaw-runtime (without default features), nemoclaw-tofu, and
tf-provider, which the fixture provider needs. Building
openshell-provider or fabric-provider tests alone now also compiles the
SDK.

## Validation

- Before the move, `every_type_has_a_contract_test` failed
(`managed_gateway has a contract test; remove it from ELSEWHERE`), and
the moved tests failed because `nemoclaw-fixture-provider` was missing.
Both pass after the move.
- Ran the whole nemoclaw contract binary with `--run-ignored all`
against a freshly built linux_arm64 bundle: 27 passed.
- `remote_service::` in nemoclaw-e2e (simulator through the bundle): 8
passed.
- `nemoclaw-test-fixtures` tests, including ignored: 5 passed.
- `cargo fmt --all` and `cargo clippy --workspace --all-targets -- -D
warnings` are clean on Linux. Windows and macOS were not checked
locally; CI covers them.
@wscurran wscurran added area: e2e End-to-end tests, nightly failures, or validation infrastructure chore Build, CI, dependency, or tooling maintenance platform: windows Affects native Windows environments labels Oct 28, 2026
@cv cv added this to the Roadmap: GTC DC 2026 milestone Nov 18, 2026
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 chore Build, CI, dependency, or tooling maintenance platform: windows Affects native Windows environments v1 NemoClaw v1 branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants