mirror of https://github.com/fafhrd91/actix-web
Add a test for hash_key()
This commit is contained in:
parent
e66312b664
commit
44e65fcaf9
|
@ -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);
|
||||
|
|
Loading…
Reference in New Issue