Skip to content

Commit 2a4fe76

Browse files
committed
Add TLS handshaking comment in test
This adds a comment in it_connects_tls_both_with_delayed_server_read because it's not obvious what it is for by simply seeing the code.
1 parent 6b467d3 commit 2a4fe76

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tests/main.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,10 @@ fn it_connects_tls_both() {
216216
#[test]
217217
#[cfg(feature = "tls")]
218218
fn it_connects_tls_both_with_delayed_server_read() {
219+
// This test is to ensure correctly handle the case when we read both the pre-TLS data as well
220+
// as (at least part of) the TLS handshake into our the buffer. When that happens, we need to
221+
// ensure we correctly pass that TLS part of the data to rustls so that is can handle the TLS
222+
// handshake properly.
219223
use std::{marker::PhantomData, sync::Arc};
220224

221225
struct MyShim<RW> {

0 commit comments

Comments
 (0)