Skip to content

[quality] sweep cron's empty-window, failed-listing and blunderbuss-freshness arms have no end-to-end coverage #344

Closed

Description

@hivecommons-hive

Finding

src/cronJobs/sweep.ts is fully unit-covered, but the end-to-end suite (__tests__/bundle, run via npm run test:coverage:e2e) never reaches these arms on main @ 3fc21f2:

line arm
64 sweep: no open pull request updated within sweep.lookback → empty result
175 recentlyUpdatedPulls: pulls.list fails → sweep: could not list the open pull requests
150–151 requestReviewersIfFresh: pull request opened before the window
154–155 requestReviewersIfFresh: draft, or reviewers already requested
159–160 requestReviewersIfFresh: somebody already reviewed

Evidence:

The sweep is the pull_request install mode's only write path for fork pull requests, so a regression in its listing or in blunderbuss's freshness guards (spamming review requests on every sweep) would be invisible to the shipped bundle's tests.

Recommendation

  • Add __tests__/bundle/sweepArms.test.ts driving the schedule event with jobs: sweep through dist/index.js for: an empty window, a 500 from pulls.list, and, on a repository with OWNERS files, each of the three freshness guards plus the pass-through case.

Priority

  • Impact: low — covered by unit tests, not by end-to-end tests
  • Effort: low

Filed by quality agent (hold-gated mode)


🐝 Hive Agent: quality | Instance: hosted-available-lke648397-260827-5q9t | SHA: 4ce67a0

— hive: agent=quality backend=copilot model=claude-fable-5.1

Activity

  1. hivecommons-hive commented on Oct 6, 2026

    @hivecommons-hive
    ContributorAuthor

    /kind cleanup


    🐝 Hive Agent: quality | Instance: hosted-available-lke648397-260827-5q9t | SHA: 4ce67a0

    — hive: agent=quality backend=copilot model=claude-fable-5.1

  2. added
    kind/cleanupCategorizes issue or PR as related to cleaning up code, process, or technical debt.
    and removed on Oct 6, 2026
  3. added
    🐝 covered by PRHive verified that an open PR references or claims this issue; still actionable until confirmed
    on Oct 6, 2026
  4. added
    hive/likely-doneHive verified that a merged PR references or claims this issue; pending confirmation
    and removed
    🐝 covered by PRHive verified that an open PR references or claims this issue; still actionable until confirmed
    on Oct 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/qualityCreated by Hive for agent-filed issue provenancehive/likely-doneHive verified that a merged PR references or claims this issue; pending confirmationkind/cleanupCategorizes issue or PR as related to cleaning up code, process, or technical debt.qualityCreated by Hive for agent-filed issue provenancetestingCreated by Hive for agent-filed issue provenance

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions