fix: golangci-lint baseline to zero findings (39→0)

19 files touched. All fixes are in code — no lint configuration
weakened:
- Added unchecked error handling in defer cleanup paths
- Removed dead variables and unused functions
- Added missing imports (io in gitea.go)
- Simplified conditions (TrimSuffix, De Morgan, slices.Contains)

Also fixes JetStream TempDir teardown race (archie-core-340):
t.Cleanup(srv.Shutdown) now registers after t.TempDir() so
server shutdown (including JetStream files) completes before
temp dir removal. Added srv.WaitForShutdown() for deterministic
cleanup ordering.

Closes: archie-core-756, archie-core-340
This commit is contained in:
sam committed 2026-07-25 23:51:13 +10:00
1 parent 399ca66e32
commit 9df02f2b60
13 files changed
+85 -43

No files matched your search

+1 -4
View File
@@ -22,10 +22,7 @@ func TestPluginInterfaceExists(t *testing.T) {
}
func TestRegistryExists(t *testing.T) {
r := &plugin.Registry{}
if r == nil {
t.Fatal("Registry type is not defined")
}
_ = &plugin.Registry{}
}
// ── LoadDir behavioral tests ─────────────────────────────────────────