swift test --enable-code-coverage passed 112 tests, but the generated SwiftPM coverage report measured Sources/ARCP at only 74.58% line coverage, with 3,477 covered lines out of 4,662. Several public or critical files are untested or substantially under-tested, including Sources/ARCP/Auth/JWTAuth.swift at 0%, Sources/ARCP/Transport/WebSocketTransport.swift at 0%, Sources/ARCP/Trace/TraceContext.swift at 0%, Sources/ARCP/Runtime/JobContext.swift at 0%, Sources/ARCP/Runtime/StreamManager.swift at 12.12%, Sources/ARCP/Auth/AuthScheme.swift at 14.81%, Sources/ARCP/Runtime/LeaseManager.swift at 32.77%, and Sources/ARCP/Runtime/SubscriptionManager.swift at 35.51%. The generated report did not include coverage for the arcp-cli executable target, so CLI parsing and command behavior are also effectively unmeasured by this run.
Fix prompt: Add focused unit and integration tests until measured library coverage exceeds 80% and the CLI has explicit command tests. Prioritize JWT validation success and failure cases, WebSocket transport delivery and close behavior, trace propagation, stream manager open and close paths, permission lease grant, refresh, expiry, and denial paths, subscription backfill and empty-filter behavior, and CLI send, tail, and replay command paths. Add SwiftCheck property-based tests for boundary-heavy invariants such as ModelUse glob matching, CostBudget subset checks, typed id decoding, ULID ordering, and envelope encode/decode round trips.
swift test --enable-code-coveragepassed 112 tests, but the generated SwiftPM coverage report measuredSources/ARCPat only 74.58% line coverage, with 3,477 covered lines out of 4,662. Several public or critical files are untested or substantially under-tested, includingSources/ARCP/Auth/JWTAuth.swiftat 0%,Sources/ARCP/Transport/WebSocketTransport.swiftat 0%,Sources/ARCP/Trace/TraceContext.swiftat 0%,Sources/ARCP/Runtime/JobContext.swiftat 0%,Sources/ARCP/Runtime/StreamManager.swiftat 12.12%,Sources/ARCP/Auth/AuthScheme.swiftat 14.81%,Sources/ARCP/Runtime/LeaseManager.swiftat 32.77%, andSources/ARCP/Runtime/SubscriptionManager.swiftat 35.51%. The generated report did not include coverage for thearcp-cliexecutable target, so CLI parsing and command behavior are also effectively unmeasured by this run.Fix prompt: Add focused unit and integration tests until measured library coverage exceeds 80% and the CLI has explicit command tests. Prioritize JWT validation success and failure cases, WebSocket transport delivery and close behavior, trace propagation, stream manager open and close paths, permission lease grant, refresh, expiry, and denial paths, subscription backfill and empty-filter behavior, and CLI
send,tail, andreplaycommand paths. Add SwiftCheck property-based tests for boundary-heavy invariants such asModelUseglob matching,CostBudgetsubset checks, typed id decoding, ULID ordering, and envelope encode/decode round trips.