Skip to content

TUI: extend coverage gate to Ink components (lift interim exclusion) #1501

Description

@cliffhall

Follow-up to #1484, which added a per-file coverage gate for the CLI and TUI.

Context

#1484 brought the TUI's non-React logic under the coverage gate (server resolution, file logger, tab metadata, and the form/URL helpers under src/utils/). The TUI's React/Ink surface was deferred as a documented interim exclusion in clients/tui/vitest.config.ts:

  • src/App.tsx (~1878 lines)
  • src/components/**/*.tsx (~16 Ink components: tabs, modals, per-capability tabs)
  • src/hooks/** (useSelectableList — needs a React renderer)

These need an Ink renderer (e.g. ink-testing-library) to exercise, which is a sizable, separate effort.

Goal

  • Add ink-testing-library (or equivalent) and write render/interaction tests for the Ink components, App.tsx, and useSelectableList.
  • Remove the corresponding entries from the exclude list in clients/tui/vitest.config.ts as each area reaches the gate (lines ≥ 90, statements ≥ 85, functions ≥ 80, branches ≥ 50).
  • Goal end-state: the whole clients/tui/src tree is under the gate with no React-surface exclusions.

Acceptance criteria

  • Ink components and App.tsx are exercised under coverage instrumentation.
  • The interim React exclusions in clients/tui/vitest.config.ts are removed.
  • CI fails when TUI component coverage drops below the gate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    v2Issues and PRs for v2

    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