Skip to content

Raise branch coverage above the 80 percent threshold #37

@nficano

Description

@nficano

The suite passes and line coverage exceeds the requested threshold, but branch coverage does not. Running asdf exec bundle exec rspec with the existing SimpleCov setup produced 86.67 percent line coverage and 56.73 percent branch coverage. The largest uncovered branch areas include lib/arcp/transport/stdio_transport.rb at 0 of 12 branches, lib/arcp/transport/websocket_transport.rb at 0 of 12 branches, lib/arcp/runtime/session_actor.rb at 25 of 54 branches, lib/arcp/client.rb at 41 of 65 branches, lib/arcp/runtime/job_manager.rb at 34 of 56 branches, lib/arcp/runtime/lease_manager.rb at 13 of 26 branches, lib/arcp/serializer.rb at 3 of 10 branches, and several event body decoders with zero covered error branches.

Fix prompt: Add focused specs until SimpleCov branch coverage is at least 80 percent, prioritizing protocol error paths and transport edge cases rather than superficial line hits. Cover stdio and websocket close and EOF behavior with test doubles, client closed-transport waiters, subscription history and feature-negotiation branches, budget denial branches, serializer backend selection and invalid backend errors, result chunk encoding errors, and session actor error replies. Add a SimpleCov minimum branch threshold so regressions fail locally and in CI.

Metadata

Metadata

Assignees

No one assigned

    Labels

    severity:mediumMedium severitytestingTest coverage and test infrastructure

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions