diff --git a/actix-http/src/ws/proto.rs b/actix-http/src/ws/proto.rs index ad42b7a6b..630c5c614 100644 --- a/actix-http/src/ws/proto.rs +++ b/actix-http/src/ws/proto.rs @@ -277,6 +277,12 @@ mod test { assert_eq!(format!("{}", OpCode::Bad), "BAD"); } + #[test] + fn test_hash_key() { + let hash = hash_key(b"hello actix-web"); + assert_eq!(&hash, "cR1dlyUUJKp0s/Bel25u5TgvC3E="); + } + #[test] fn closecode_from_u16() { assert_eq!(CloseCode::from(1000u16), CloseCode::Normal);