Commit 7062c20
installer: PR26.5 — seed stub binaries in test mock for CI
Auditor flagged: TestStageAll_AllUnitNftbanOwnedExecStartPathsStaged_PR26_5
fails on CI because the runner ships a clean source checkout with no
prebuilt binaries. lab2 happened to have prebuilt binaries from prior
builds, so the test passed there. The test's intent is correct (assert
every shipped unit's nftban-owned ExecStart path is staged), but it
needs the binary source files to exist for the staging step to succeed.
Fix: per auditor option 1, add a `seedStubBuiltBinaries` helper that
populates `bin/<name>` with a stub byte-string in the test mock before
StageAll. Production payload.go is unchanged.
Helper applied to all 3 PR26.5 tests for environment consistency:
TestStageAll_AllUnitNftbanOwnedExecStartPathsStaged_PR26_5 (the failing one)
TestStageAll_AllPanelConfDStaged_PR26_5
TestStageAll_PR26_5_NewShellCategoriesStaged
Lab proof — confirmed reproducer:
rm -rf /root/nftban-src/bin && go test -count=1 -v -run PR26_5 ./...
→ all 3 PR26.5 tests PASS (was: 1 FAIL pre-fix on empty bin/)
go test ./...
→ 66 packages PASS, 0 FAIL
Production code: unchanged. The fix is fixture-only — no payload.go
edits, no validate/ edits, no buildEntries change.
Hard exclusions still preserved: no takeover preservation, no CSF
binary handling, no cPanel/Plesk adapters, no shell decommission, no
parser rewrite, no restore changes, no firewall mutation, no
destructive dns2 retry.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 4a1dd31 commit 7062c20
1 file changed
Lines changed: 31 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
689 | 689 | | |
690 | 690 | | |
691 | 691 | | |
| 692 | + | |
| 693 | + | |
| 694 | + | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
692 | 711 | | |
693 | 712 | | |
694 | 713 | | |
| |||
698 | 717 | | |
699 | 718 | | |
700 | 719 | | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
701 | 724 | | |
702 | 725 | | |
703 | 726 | | |
| |||
748 | 771 | | |
749 | 772 | | |
750 | 773 | | |
| 774 | + | |
| 775 | + | |
| 776 | + | |
| 777 | + | |
| 778 | + | |
| 779 | + | |
751 | 780 | | |
752 | 781 | | |
753 | 782 | | |
| |||
788 | 817 | | |
789 | 818 | | |
790 | 819 | | |
| 820 | + | |
| 821 | + | |
791 | 822 | | |
792 | 823 | | |
793 | 824 | | |
| |||
0 commit comments