Added context cancellation tests.

This commit is contained in:
Jay
2026-04-18 18:01:22 -04:00
parent b4c5c897e8
commit 8d79a002f8
4 changed files with 203 additions and 5 deletions

View File

@@ -47,6 +47,12 @@ func AcquireSocket(
url string,
logger *slog.Logger,
) (types.Socket, *http.Response, error) {
select {
case <-ctx.Done():
return nil, nil, ctx.Err()
default:
}
if retryMgr == nil {
return nil, nil, NewConnectionError("retry manager cannot be nil")
}