continuwuity/src/core/pdu/tests.rs
Jason Volk 79c6b51860 renames for core pdu
Signed-off-by: Jason Volk <jason@zemos.net>
2024-11-08 06:09:04 +00:00

19 lines
435 B
Rust

#![cfg(test)]
use super::Count;
#[test]
fn backfilled_parse() {
let count: Count = "-987654".parse().expect("parse() failed");
let backfilled = matches!(count, Count::Backfilled(_));
assert!(backfilled, "not backfilled variant");
}
#[test]
fn normal_parse() {
let count: Count = "987654".parse().expect("parse() failed");
let backfilled = matches!(count, Count::Backfilled(_));
assert!(!backfilled, "backfilled variant");
}