mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-15 00:00:15 +02:00
Fix line-frames test
This commit is contained in:
@@ -57,10 +57,10 @@ fn echo() {
|
||||
assert_eq!(amt, 2);
|
||||
assert_eq!(&buf[..2], b"a\n");
|
||||
|
||||
let (client, _) = core.run(write_all(client, b"\nb\n")).unwrap();
|
||||
let (client, _) = core.run(write_all(client, b"\n")).unwrap();
|
||||
let (client, buf, amt) = core.run(read(client, buf)).unwrap();
|
||||
assert_eq!(amt, 3);
|
||||
assert_eq!(&buf[..3], b"\nb\n");
|
||||
assert_eq!(amt, 1);
|
||||
assert_eq!(&buf[..1], b"\n");
|
||||
|
||||
let (client, _) = core.run(write_all(client, b"b")).unwrap();
|
||||
client.shutdown(Shutdown::Write).unwrap();
|
||||
|
||||
Reference in New Issue
Block a user