mirror of
https://github.com/mudler/LocalAI.git
synced 2026-10-28 09:08:54 -04:00
test(addons): discard the close error of the held listener
errcheck flags the deferred Close of the listener that keeps the port busy. The test has no use for that error, so the defer drops it explicitly. Assisted-by: Claude Code:claude-sonnet-5-5 go Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
This commit is contained in:
1 file changed
+1
-1
@@ -57,7 +57,7 @@ func TestLoopbackPortInUseFailsClearly(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
defer held.Close()
|
||||
defer func() { _ = held.Close() }()
|
||||
_, _, err = NewLoopbackCarrierConfig("local", root)
|
||||
if err == nil {
|
||||
t.Fatal("expected an error while the port is in use")
|
||||
|
||||
Reference in new issue
Block a user