r/coolgithubprojects • u/ChrisShips • 4h ago
honest-ci: a GitHub Action that holds a PR for a person when it deletes, skips or rewrites tests (free on public repos)
I made honest-ci. It's a GitHub Action that reads a PR's diff for the ways tests get weaker while CI stays green. It has five rules, one for each way:
- a test, a named table case or a whole test file disappears
- a new skip, xfail, todo or
.onlyshows up - a test file loses assertions
- an expected value changes and nothing else in the assertion does, in a PR that also changes code
- a coverage threshold drops, or tests get left out of the run (
--ignore,-k "not ...",-DskipTests,|| true)
The first four hold the PR for a person, and the comment names the test and how it changed. The last one blocks. It knows Python, JS/TS, Java and Go tests.
Verdicts come from deterministic code. You can add a model to explain findings, but it never decides. A first install needs no Docker and no test setup, just one command that writes the workflow and two config files. The rules are read at the PR's base commit, so a PR can't loosen the rules it's judged by. An approval only counts for the commit it was given on.
I ran it on 2,717 PRs from public repos, opened by coding agents and by people, and labeled all 345 flags. 93.6% of them were true statements about the diff. Every label is in the repo under bench/data, with a link to the line.
It's source-available, free on public repos and on private repos where only you open PRs. A team's private repos need a subscription after a 14-day trial.
