mirror of
https://github.com/actix/actix-web.git
synced 2024-12-17 05:36:36 +00:00
Check WS stream completed after close.
This commit is contained in:
parent
ff8fd2f7b5
commit
d3911ec285
1 changed files with 4 additions and 0 deletions
|
@ -65,4 +65,8 @@ async fn test_simple() {
|
|||
|
||||
let item = framed.next().await.unwrap().unwrap();
|
||||
assert_eq!(item, ws::Frame::Close(Some(ws::CloseCode::Normal.into())));
|
||||
|
||||
let nothing = actix_rt::time::timeout(std::time::Duration::from_secs(1), framed.next()).await;
|
||||
assert_eq!(true, nothing.is_ok());
|
||||
assert_eq!(true, nothing.unwrap().is_none());
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue