refactor(apple): share simulator status-bar diagnostics

Merged
TH
4d ago
+171-23

Summary

Let the simulator status-bar module own the diagnostic emitter used during status-bar preparation and screenshot capture. Both modules previously constructed the same warning payload independently. Sharing the emitter preserves all three phases, normalized tool-error metadata and device identity fields while preventing the payloads from drifting.

Five files change: two production modules, two existing test suites and their shared diagnostic-log helper. Production source shrinks by 10 lines and 89 bytes including import/export/comment overhead; CI measures installed/unpacked size −145 B and compressed download +8 B. No linked issue or production scope expansion. Capture routes, restoration order, deadlines and image output are unchanged.

Validation

  • Head f86926fe44fdc666f388f8d5fef12075538f029c; base eedc0df3d2168275dcd89ed21613c3362d595731.
  • AGENT_DEVICE_VITEST_MAX_WORKERS=1 pnpm check:affected --run --head f86926fe44fdc666f388f8d5fef12075538f029c: passed, exactCommit: true; receipt run-r4l2um, 7 passed / 2 deduplicated / 4 skipped checks, 1,196 related tests passed.
  • Independent Apex review at 422737d found two low test issues. Follow-up stubs the unrelated display probe and shares one parsed-log helper, removing 32 test-support lines. Both findings fixed locally; 29 focused tests passed. Production behavior received no findings.
  • GitHub owns full coverage, package-size and platform smoke evidence. Parked replay lanes were skipped locally. No live device behavior changes, so manual device verification is not required.