refactor(tests): reformat code and update dependency management
- Reorganized import statements in adapter tests for better readability - Replaced or_insert_with(Vec::new) with or_default() in test closures - Updated Cargo.lock with new dependency versions and checksums - Added TLS features to tonic dependency configuration - Included sqlx, chrono, and uuid dependencies with specific features - Added jsonwebtoken and arc-swap as project dependencies - Reformatted assertion statements to comply with line length limits - Adjusted base64 import order in engine codec module - Updated protobuf include statement formatting
This commit is contained in:
+6
-3
@@ -1,4 +1,4 @@
|
||||
use base64::{engine::general_purpose::STANDARD as BASE64, Engine};
|
||||
use base64::{Engine, engine::general_purpose::STANDARD as BASE64};
|
||||
|
||||
use crate::engine::packet::{Packet, PacketData, PacketError, PacketType};
|
||||
|
||||
@@ -226,7 +226,10 @@ mod tests {
|
||||
let input: Vec<u8> = vec![b'4', 0x80, 0xFF, 0x00, 0x01];
|
||||
let decoded = decode_packet_ws(&input).unwrap();
|
||||
assert_eq!(decoded.packet_type, PacketType::Message);
|
||||
assert_eq!(decoded.data, PacketData::Binary(vec![0x80, 0xFF, 0x00, 0x01]));
|
||||
assert_eq!(
|
||||
decoded.data,
|
||||
PacketData::Binary(vec![0x80, 0xFF, 0x00, 0x01])
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
@@ -236,4 +239,4 @@ mod tests {
|
||||
assert_eq!(decoded.packet_type, PacketType::Message);
|
||||
assert_eq!(decoded.data, PacketData::Empty);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user