feat: name filtered state in issue list count line (task 0033)
Some checks failed
CI / test (pull_request) Failing after 54s

Make the `issue list` count line name the state it filtered on, so the
answer to "how many issues are open?" is present on the summary line
rather than only inferable from each row. The count line now renders
`count: 5 open of 5 total`; the command composes the state into a generic
optional qualifier while `formatCountLine` stays state-agnostic, so
`pr list`, `search`, and `dashboard` are unaffected. `--state all` imposes
no narrowing and stays unqualified.

The wording is chosen so an agent quoting the summary lands on a phrase the
benchmark read-checker already accepts (`5 open`), closing the accuracy gap
this feature targets. Pairs with the report persistence in task 0032.
This commit is contained in:
2026-07-17 10:09:50 -04:00
parent 4cbed21ff3
commit 1166a48130
5 changed files with 77 additions and 12 deletions

View File

@@ -122,7 +122,7 @@ describe("repository context detection", () => {
});
expect(exitCode).toBe(0);
expect(stdout).toContain("count: 3 of 3 total");
expect(stdout).toContain("count: 3 open of 3 total");
expect(server!.requests[0]!.headers.authorization).toBe("Bearer detected-token");
// Auto-detected context: suggestions must not carry override flags.
expect(stdout).not.toContain("-R testowner/testrepo");
@@ -143,7 +143,7 @@ describe("repository context detection", () => {
});
expect(exitCode).toBe(0);
expect(stdout).toContain("count: 3 of 3 total");
expect(stdout).toContain("count: 3 open of 3 total");
});
it("fails with REPO_NOT_FOUND when there is no recognizable origin remote", async () => {