From b9ddbaf03f5593ddb10263fb92d5f78d1dbca8bf Mon Sep 17 00:00:00 2001 From: Raoul Strackx Date: Mon, 6 Nov 2023 11:40:03 +0100 Subject: [PATCH] Ignore peek tests on SGX platform --- tokio/tests/tcp_into_split.rs | 1 + tokio/tests/tcp_split.rs | 1 + 2 files changed, 2 insertions(+) diff --git a/tokio/tests/tcp_into_split.rs b/tokio/tests/tcp_into_split.rs index 35265588845..52c0a4f240c 100644 --- a/tokio/tests/tcp_into_split.rs +++ b/tokio/tests/tcp_into_split.rs @@ -44,6 +44,7 @@ async fn split() -> Result<()> { assert_eq!(peek_len1, peek_len2); let read_len = read_half.read(&mut read_buf[..]).await?; + #[cfg(not(target_env = "sgx"))] // peek always returns Ok(0) in SGX assert_eq!(peek_len1, read_len); assert_eq!(&read_buf[..read_len], MSG); Ok(()) diff --git a/tokio/tests/tcp_split.rs b/tokio/tests/tcp_split.rs index 6ef91b85854..53f350adfef 100644 --- a/tokio/tests/tcp_split.rs +++ b/tokio/tests/tcp_split.rs @@ -33,6 +33,7 @@ async fn split() -> Result<()> { assert_eq!(peek_len1, peek_len2); let read_len = read_half.read(&mut read_buf[..]).await?; + #[cfg(not(target_env = "sgx"))] // peek always returns Ok(0) in SGX assert_eq!(peek_len1, read_len); assert_eq!(&read_buf[..read_len], MSG);