Skip to content

Commit 5b555f5

Browse files
committed
Fix test_conn_error_other on mac
1 parent b3c1861 commit 5b555f5

File tree

1 file changed

+7
-1
lines changed
  • pingora-core/src/connectors

1 file changed

+7
-1
lines changed

pingora-core/src/connectors/l4.rs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,13 @@ mod tests {
385385
let new_session = connect(&peer, Some(bind_to)).await;
386386
let error = new_session.unwrap_err();
387387
// XXX: some system will allow the socket to bind and connect without error, only to timeout
388-
assert!(error.etype() == &ConnectError || error.etype() == &ConnectTimedout)
388+
assert!(
389+
error.etype() == &ConnectError
390+
|| error.etype() == &ConnectTimedout
391+
// The error seen on mac: https://github.com/cloudflare/pingora/pull/679
392+
|| (error.etype() == &InternalError),
393+
"{error:?}"
394+
)
389395
}
390396

391397
#[tokio::test]

0 commit comments

Comments
 (0)