Commit fde7f36
committed
Restore the CSV negative control that a
The previous commit claimed to add a negative control to the byte-identity
check. It did not. The control never reached GitHub, CI went green anyway
because there was nothing there to fail, and the commit message asserted a
guard that did not exist.
Cause: while testing the pre-commit hook's own control, the cleanup line was
`git commit --allow-empty && git reset --hard HEAD~1`. `reset --hard` discards
working-tree changes, and the edit to this workflow was uncommitted at the
time. The fixture teardown ate the feature.
Third time today a destructive git command used as test cleanup destroyed real
uncommitted work -- twice `git checkout -- <file>` reverting a fix along with
an injected fixture, now `reset --hard`. Convenience git commands take a wider
scope than the intent behind them, and none of the three announced what they
removed.
The failure this produced is exactly the one the control exists to prevent: a
check that is green because it checks nothing. It was found by grepping the
pushed file for the control's own output string rather than trusting a green
run -- CI passing is not evidence that the thing you added is running.
Teardown for a mutation fixture is now `cp` from a backup, never `checkout`,
`reset` or `clean`.git reset --hard silently deleted1 parent 4dc6f28 commit fde7f36
1 file changed
Lines changed: 18 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
63 | 81 | | |
64 | 82 | | |
65 | 83 | | |
| |||
0 commit comments