Skip to content

Commit

Permalink
Small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
artemijan committed Feb 23, 2025
1 parent edd50ab commit 7e66d92
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions l2-core/src/traits/handlers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -289,8 +289,8 @@ mod test {
);
client.write_all(&[0, 0, 0, 0, 0, 0, 0, 0]).await.unwrap();
let err = handler.handle_client().await;
// assert!(handler.on_connect_called == 1);
// assert!(handler.on_disconnect_called == 1);
assert_eq!(handler.on_connect_called, 1);
assert_eq!(handler.on_disconnect_called, 1);
assert!(err.is_err());
assert!(
matches!(err, Err(e) if e.to_string() == "Error receiving packet: Packet size is 0, it's not expected")
Expand Down Expand Up @@ -318,8 +318,8 @@ mod test {
tokio::time::sleep(time::Duration::from_millis(500)).await;
client.shutdown().await.unwrap();
let handler = handle.await.unwrap();
assert!(handler.on_connect_called == 1);
assert!(handler.on_disconnect_called == 1);
assert_eq!(handler.on_connect_called, 1);
assert_eq!(handler.on_disconnect_called, 1);
assert_eq!(handler.on_receive_bytes, vec![(6, vec![0, 0, 0, 0, 0, 0])]);
}
}

0 comments on commit 7e66d92

Please sign in to comment.