diff options
author | Lucio Franco <luciofranco14@gmail.com> | 2020-01-21 14:19:36 -0500 |
---|---|---|
committer | Carl Lerche <me@carllerche.com> | 2020-01-21 11:19:36 -0800 |
commit | c7719a2d2962f83854193b4c9131ee275a5a4475 (patch) | |
tree | 6e451b8b346ce258ee9d5f8bd7b1b65bb1199853 /tokio/tests/io_split.rs | |
parent | 38bff0adda393f8121225727d93cb342d8363979 (diff) |
io: simplify split check (#2144)
* io: Clean up split check
* fix tests
Diffstat (limited to 'tokio/tests/io_split.rs')
-rw-r--r-- | tokio/tests/io_split.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tokio/tests/io_split.rs b/tokio/tests/io_split.rs index f6326ae9..e54bf248 100644 --- a/tokio/tests/io_split.rs +++ b/tokio/tests/io_split.rs @@ -49,10 +49,10 @@ fn is_send_and_sync() { fn split_stream_id() { let (r1, w1) = split(RW); let (r2, w2) = split(RW); - assert_eq!(r1.stream_id(), w1.stream_id()); - assert_eq!(r1.stream_id(), w1.stream_id()); - assert_ne!(r1.stream_id(), w2.stream_id()); - assert_ne!(r2.stream_id(), w1.stream_id()); + assert_eq!(r1.is_pair_of(&w1), true); + assert_eq!(r1.is_pair_of(&w2), false); + assert_eq!(r2.is_pair_of(&w2), true); + assert_eq!(r2.is_pair_of(&w1), false); } #[test] |