Skip to content

test(firmware): cover S-record high address workflows - #8897

Merged
morluto merged 1 commit into
morluto:mainfrom
ShuaixinHuang:codex/test-srec-address-widths
Nov 4, 2026
Merged

morluto merged 1 commit into
morluto:mainfrom
ShuaixinHuang:codex/test-srec-address-widths

Conversation

@ShuaixinHuang

@ShuaixinHuang ShuaixinHuang commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Supersedes #8881 at the author's request. The branch and code are unchanged; this new PR requires its own CI and initial author readiness confirmation.

Current CI blocker: the selected upstream baseline has a duplicate childNodes import in electronCallPathBlockPrefixes.ts (TS2300). Both Static checks and Build package fail before the added acceptance tests. Independent build repair: #8884. The S-record test diff remains unchanged.

Summary

Cover S28 high addresses in the compiled CLI and full/compact stdio MCP workflows, plus unsigned S37 addresses in the CLI. Existing CLI coverage selects S19, and existing MCP S37 coverage uses an address below the signed 32-bit boundary. No issue is linked: this is an independently identified public-workflow coverage gap.

Problem and expected behavior

S28 address 0x00fedcba and S37 address 0xfedcba98 must survive inventory and extraction without losing high bits or changing the source file. Literal checksum-valid records expect a deadbeef region and the corresponding S8/S7 start address.

Change and scope

Two test files add four scenarios. They check variant/start-address metadata, region names, exact extracted bytes and unchanged source bytes. Existing malformed-record and compact/full schema checks remain exercised. Contribution scope: independent test coverage for existing functionality; maintainer scope decision not applicable.

Contract and boundary impact

  • Semantic owner and earliest changed stage: existing S-record parser and artifact inventory/extraction; production implementation unchanged.
  • CLI and MCP/tool-catalog contract: existing contracts exercised through compiled public adapters.
  • Provider, bridge, target-format or platform compatibility: no new support claimed.
  • Evidence, authority, cleanup or reconstruction contract: existing extraction containment and fixture cleanup exercised.
  • Generated metadata, package or installation impact: none.

Expected effects:

  • Read existing files or captured data.
  • Launch or attach to a process.
  • Change process memory, registers, files, or configuration.

These describe test-owned fixture files, extraction outputs and owned REA CLI/server processes. Firmware is not executed.

Evidence and regression coverage

  • Added CLI S28/S37 and full/compact MCP S28 scenarios.
  • No runtime defect or failing production baseline is claimed. The original public tests had no S28 scenario and no high unsigned S37 CLI address.
  • The initial test draft contained a wrong S7 checksum and used an unsupported MCP path argument; those fixture errors were corrected before the passing run.
  • Remaining gaps: synthetic records only; no flashed device, vendor firmware or Linux/macOS run. No mutation-testing or performance claim.

Validation performed

  • npm.cmd run test:focused -- tests/acceptance/hexRecordsCli.test.ts tests/boundary/mcp/hexRecordsMcp.test.ts: 11 passed in two files, including actual compiled CLI and stdio MCP.
  • npm.cmd run check:fast: typecheck and lint passed, 2 tasks, 43.389 s.
  • Repository formatter and git diff --check: passed.
  • Windows host Node 22.20.0/npm 10.9.3; child fixtures may select the existing pinned Node runtime. npm differs from the repository pin; no dependencies installed.
  • Tested in an isolated local worktree. Both changed base files match upstream b9138a1 byte for byte; the remote commit contains only these two files. The complete upstream integration tree requires its own CI.

Compatibility, safety, and release

Test-only; no migration, runtime, schema, package or release metadata change. Real-device/provider validation is not established by these synthetic fixtures.

Author readiness

Human owner: @ShuaixinHuang

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

Before merge

  • This PR addresses a concrete problem or an agreed enhancement.
  • Material scope and authority questions are resolved, and any required maintainer scope decision covers the final diff.
  • The PR has one focused outcome and the title follows type(scope): outcome.
  • Related issue is linked, or the reason for not linking one is stated above.
  • Tests cover changed observable behavior and meaningful failure paths.
  • Owning docs, contracts, and generated metadata are updated where needed.
  • User-visible CLI/MCP changes include representative output.
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-11-04T12:53:29.476135Z
We couldn’t complete this review. Comment @codex review to try again.
e7158fb PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@greptile-apps

greptile-apps Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The changed tests appear safe to merge and add useful high-address coverage.

Summary

Adds four public-workflow scenarios for S-record addresses:

  • CLI tests check high S-record addresses survive extraction.
  • MCP tests check high S28 addresses survive extraction.

No actionable issue or security concern was found in the changed tests. Tests were not run during this review.

Known issue acknowledged by ShuaixinHuang: the supplied PR description identifies the baseline duplicate childNodes import as an existing build blocker, with repair tracked separately in #8884. It is not caused by these changes.

The supplied description says this PR supersedes #8881. Whether #8897 has since been superseded could not be checked because GitHub access required authentication.

Reviews (1) · Last reviewed commit: "test(firmware): cover S-record high addr..." · Reviewed by Greptile

@morluto
morluto merged commit 25b62db into morluto:main Nov 4, 2026
90 of 97 checks passed
@morluto morluto added the area: tests Test suite and verification label Nov 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: tests Test suite and verification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants