Skip to content

test(e2e): drive the OpenClaw terminal UI in the interfaces case - #14274

Merged
cv merged 2 commits into
v1from
test/openclaw-terminal-ui-e2e
Nov 6, 2026
Merged

cv merged 2 commits into
v1from
test/openclaw-terminal-ui-e2e

Conversation

@cv

@cv cv commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator

The docker-openclaw-hermes-interfaces live case now opens OpenClaw's terminal UI the way the interfaces guide describes: through openshell sandbox exec --tty with the dashboard's token. It sends a prompt and checks that the stub model's reply appears and that Ctrl-D exits 0.

Problem

QA's GTC DC cases 030-UI and 032-UI chat with OpenClaw through openclaw tui over openshell sandbox exec --tty, and #14269 documents and reports that command. No automated test opens a terminal UI: the interfaces case checks only the Control UI's HTTP endpoints, and hcl_live::command runs commands with --no-tty.

Change

  • hcl_live::terminal, a new probe:
    • reads the token file that apply reports, with openshell sandbox exec --no-tty, and puts it in place of a TOKEN argument;
    • runs the pinned openshell sandbox exec --tty -- COMMAND in a 40-by-120 pseudo-terminal from nix::pty::openpty, waits for a ready text, then types the prompt and Enter separately (a terminal UI reads a prompt and Enter that arrive together as a paste);
    • waits for the reply, sends Ctrl-D and waits for the exit.
    • Its report holds whether the ready text and the reply appeared, and the exit status. The screen output and the token stay in the private work directory.
  • tests/e2e/hcl/terminal, a module that runs the probe once per target and lists the targets that failed, as tests/e2e/hcl/command does.
  • The interfaces case's new terminal run opens openclaw tui --url ws://127.0.0.1:18789 --token TOKEN in claw, with the dashboard's token path from apply's result. It waits for connected | idle and expects nemoclaw-stub-reply.
  • A unit test covers how the probe strips control sequences from the screen output.
  • nix becomes a Unix-only dev-dependency of nemoclaw-e2e; the workspace already pins it with the term feature. The workspace forbids unsafe, so the probe doesn't make the pseudo-terminal the command's controlling terminal. openshell sandbox exec --tty doesn't need one.

Left out: Hermes's browser chat through the dashboard's /api/pty WebSocket. It needs the dashboard's session token and its Host and Origin checks on a forwarded port, and Hermes's terminal UI took 15 to 30 s to start in earlier manual runs. Whether it is reliable in CI is unestablished, so it stays a manual check, as internal-docs/contributing/live-tests.md says.

Beyond CI

On linux_arm64, cargo ci live-docker --hcl-cases docker-openclaw-hermes-interfaces passed. The case took 51.5 s. In an earlier run with a second target that expected a different reply, which failed as expected and was removed before commit, the other run blocks took 42.7 s together, so the terminal run adds about 9 s.

@cv

cv commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author
Authoring session — opening
Field Status Value Evidence or limit
Harness recorded Pi 1.5.0 Session metadata and installed release path
Skills recorded test-driven-development (complete read); write-tests (complete read); nemoclaw-contributor-create-pr (complete read) Tool reads to cutoff
Instruction files recorded AGENTS.md (injected); WRITING.md (complete read); .github/PULL_REQUEST_TEMPLATE.md (complete read); .github/SESSION_REPORT_TEMPLATE.md (complete read) Startup injection and tool reads to cutoff
Tool calls partial typescript: 173 Includes failed calls, to cutoff, for the whole session; the typescript wrapper hides its nested shell, git, and file calls
Session window recorded 2026-11-06T13:33Z to 2026-11-06T15:07Z; 94 min First event to cutoff, including idle time; the session also investigated the design and wrote #14269 before this change
Compactions recorded 0 Complete record to cutoff
Models recorded aws/anthropic/bedrock-claude-opus-5-5 Model change events; no changes
Reasoning levels recorded high Thinking-level events; no changes

@cv
cv enabled auto-merge (squash) November 6, 2026 15:07
@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

…ui-e2e

# Conflicts:
#	internal-docs/contributing/live-tests.md
@cv
cv merged commit 24601f8 into v1 Nov 6, 2026
66 checks passed
@cv
cv deleted the test/openclaw-terminal-ui-e2e branch November 6, 2026 15:59
@wscurran wscurran added area: e2e End-to-end tests, nightly failures, or validation infrastructure area: security Security controls, permissions, secrets, or hardening chore Build, CI, dependency, or tooling maintenance integration: openclaw OpenClaw integration behavior v1 NemoClaw v1 branch labels Nov 12, 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: e2e End-to-end tests, nightly failures, or validation infrastructure area: security Security controls, permissions, secrets, or hardening chore Build, CI, dependency, or tooling maintenance integration: openclaw OpenClaw integration behavior v1 NemoClaw v1 branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants