use super::{Ratio, Rational};
#[test]
fn deserialize() {
assert!(
serde_json::from_str::<Rational::<u8>>(r#""2/3""#)
.is_ok_and(|r| r.0 == Ratio::new(2u8, 3u8))
);
assert!(
serde_json::from_str::<Rational::<u8>>(r#""0.67""#)
.is_ok_and(|r| r.0 == Ratio::new(67u8, 100u8))
);
}