mirror of
https://gitlab.com/veilid/veilid.git
synced 2024-10-01 01:26:08 -04:00
Added veilid_log tests.
This commit is contained in:
parent
04c52a4ddb
commit
febd5fe2dd
@ -187,7 +187,22 @@ pub async fn test_partialtunnel() {
|
||||
|
||||
assert_eq!(orig, copy);
|
||||
}
|
||||
pub async fn test_veilidloglevel() {
|
||||
let orig = VeilidLogLevel::Info;
|
||||
let copy = deserialize_json(&serialize_json(&orig)).unwrap();
|
||||
|
||||
assert_eq!(orig, copy);
|
||||
}
|
||||
pub async fn test_veilidlog() {
|
||||
let orig = VeilidLog {
|
||||
log_level: VeilidLogLevel::Debug,
|
||||
message: "A log! A log!".to_string(),
|
||||
backtrace: Some("Func1 -> Func2 -> Func3".to_string()),
|
||||
};
|
||||
let copy = deserialize_json(&serialize_json(&orig)).unwrap();
|
||||
|
||||
assert_eq!(orig, copy);
|
||||
}
|
||||
pub async fn test_all() {
|
||||
test_round_trip_peerinfo().await;
|
||||
test_alignedu64().await;
|
||||
@ -204,4 +219,6 @@ pub async fn test_all() {
|
||||
test_tunnelendpoint().await;
|
||||
test_fulltunnel().await;
|
||||
test_partialtunnel().await;
|
||||
test_veilidloglevel().await;
|
||||
test_veilidlog().await;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user