[PR #1895] [CLOSED] test(apple): allow cold Swift fixture setup in keyed archive integer tests #4887

Closed
opened 2026-10-31 00:56:27 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/1895
Author: @Ghost-Kang
Created: 10/11/2026
Status: ❌ Closed

Base: main ← Head: fix/keyed-archive-integer-test-timeout


📝 Commits (1)

  • d395dee test(apple): allow cold Swift fixture setup in keyed archive integer tests

📊 Changes

1 file changed (+3 additions, -0 deletions)

View changed files

📝 tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts (+3 -0)

📄 Description

Summary

tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts times out on its first case when the full suite runs in parallel on macOS. This raises the describe-level timeout so the worker fixture's cold Swift compile no longer counts against the default 30s test budget. No linked issue; found while running npm test locally.

Problem and expected behavior

The worker-scoped fixture keyedArchiveIntegerFixtures runs xcrun swift -module-cache-path <fresh temp dir> tests/conformance/native/keyed-archive-integers.swift. With an empty module cache, Swift rebuilds the Foundation/Clang modules (~111 MB) every run: ~19s on an idle Apple Silicon machine. Vitest charges worker fixture setup to the first test that uses it, so filesystem preserves xml controls numeric meaning shares the 30s testTimeout with that compile. Under full-suite parallel load it exceeded 30s; the other 7 cases in the file pass in under 2s each.

Expected: the case should not fail because of fixture setup time it does not control.

Change and scope

Adds { timeout: 120_000 } to the describe block (same form as tests/boundary/filesystem/installScript.test.ts) plus a comment explaining why. The isolated per-run module cache is intentionally kept: the same pattern is used in scripts/verify/apple/keyed-archive.mjs and src/native/NativeUiHelperRuntime.ts, so sharing a cache was not pursued.

Contract and boundary impact

  • Semantic owner and earliest changed stage: test configuration only
  • CLI and MCP/tool-catalog contract: none
  • Provider, bridge, target-format, or platform compatibility: none (the suite is already skipped off darwin)
  • Evidence, artifact, provenance, or reconstruction contract: none
  • Process execution, authorization, cleanup, or containment impact: none
  • Generated metadata (docs/public/product-catalog.json), package, or installation impact: none

Evidence and regression coverage

  • Tests added or updated: tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts (timeout only)
  • Base reproduction or other evidence: on the base revision, full npm test failed this case with Test timed out in 30000ms; running it together with hopperBridgeReconnect.test.ts and jadxIntegration.test.ts reproduced the timeout. A fresh-cache xcrun swift -module-cache-path run took 18.8s on an idle machine.
  • User-visible CLI/MCP output: not applicable
  • Remaining proof gaps: not validated on slower Intel macOS or on CI runners

Validation performed

  • npx vitest run tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts tests/boundary/providers/hopper/hopperBridgeReconnect.test.ts tests/boundary/process/jadxIntegration.test.ts: 3 files / 42 tests passed; the first case took 19.0s
  • npm run check: passed
  • pre-commit (oxfmt, oxlint) and pre-push (check:fast): passed
  • Environment: macOS 26.6.2 (Apple Silicon), Node 24.21.0, Xcode 27.0

Compatibility, safety, and release

  • Breaking changes or migration steps: none
  • Real Hopper/Ghidra, browser, or OS coverage: macOS only, as before
  • Package or release metadata impact: none
  • Security, privacy, process, or containment review: not applicable

Review checklist

  • This PR addresses a concrete problem or an agreed enhancement.
  • 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.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/1895 **Author:** [@Ghost-Kang](https://github.com/Ghost-Kang) **Created:** 10/11/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `fix/keyed-archive-integer-test-timeout` --- ### 📝 Commits (1) - [`d395dee`](https://github.com/morluto/rea/commit/d395deed54ecd20ddc631b889a32317472d73631) test(apple): allow cold Swift fixture setup in keyed archive integer tests ### 📊 Changes **1 file changed** (+3 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts` (+3 -0) </details> ### 📄 Description ## Summary `tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts` times out on its first case when the full suite runs in parallel on macOS. This raises the describe-level timeout so the worker fixture's cold Swift compile no longer counts against the default 30s test budget. No linked issue; found while running `npm test` locally. ## Problem and expected behavior The worker-scoped fixture `keyedArchiveIntegerFixtures` runs `xcrun swift -module-cache-path <fresh temp dir> tests/conformance/native/keyed-archive-integers.swift`. With an empty module cache, Swift rebuilds the Foundation/Clang modules (~111 MB) every run: ~19s on an idle Apple Silicon machine. Vitest charges worker fixture setup to the first test that uses it, so `filesystem preserves xml controls numeric meaning` shares the 30s `testTimeout` with that compile. Under full-suite parallel load it exceeded 30s; the other 7 cases in the file pass in under 2s each. Expected: the case should not fail because of fixture setup time it does not control. ## Change and scope Adds `{ timeout: 120_000 }` to the `describe` block (same form as `tests/boundary/filesystem/installScript.test.ts`) plus a comment explaining why. The isolated per-run module cache is intentionally kept: the same pattern is used in `scripts/verify/apple/keyed-archive.mjs` and `src/native/NativeUiHelperRuntime.ts`, so sharing a cache was not pursued. ## Contract and boundary impact - Semantic owner and earliest changed stage: test configuration only - CLI and MCP/tool-catalog contract: none - Provider, bridge, target-format, or platform compatibility: none (the suite is already skipped off darwin) - Evidence, artifact, provenance, or reconstruction contract: none - Process execution, authorization, cleanup, or containment impact: none - Generated metadata (`docs/public/product-catalog.json`), package, or installation impact: none ## Evidence and regression coverage - Tests added or updated: `tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts` (timeout only) - Base reproduction or other evidence: on the base revision, full `npm test` failed this case with `Test timed out in 30000ms`; running it together with `hopperBridgeReconnect.test.ts` and `jadxIntegration.test.ts` reproduced the timeout. A fresh-cache `xcrun swift -module-cache-path` run took 18.8s on an idle machine. - User-visible CLI/MCP output: not applicable - Remaining proof gaps: not validated on slower Intel macOS or on CI runners ## Validation performed - `npx vitest run tests/boundary/filesystem/keyedArchiveNativeIntegers.test.ts tests/boundary/providers/hopper/hopperBridgeReconnect.test.ts tests/boundary/process/jadxIntegration.test.ts`: 3 files / 42 tests passed; the first case took 19.0s - `npm run check`: passed - pre-commit (oxfmt, oxlint) and pre-push (`check:fast`): passed - Environment: macOS 26.6.2 (Apple Silicon), Node 24.21.0, Xcode 27.0 ## Compatibility, safety, and release - Breaking changes or migration steps: none - Real Hopper/Ghidra, browser, or OS coverage: macOS only, as before - Package or release metadata impact: none - Security, privacy, process, or containment review: not applicable ## Review checklist - [x] This PR addresses a concrete problem or an agreed enhancement. - [x] The PR has one focused outcome and the title follows `type(scope): outcome`. - [x] Related issue is linked, or the reason for not linking one is stated above. - [x] Tests cover changed observable behavior and meaningful failure paths. - [x] Owning docs, contracts, and generated metadata are updated where needed. - [x] User-visible CLI/MCP changes include representative output. - [x] I checked the final diff for secrets, unrelated cleanup, and unsupported claims. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 00:56:27 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#4887
No description provided.