test with more laws

This commit is contained in:
philipp 2023-11-04 00:12:14 +01:00
parent 68fd81d308
commit cf2e978465
3 changed files with 14006 additions and 0 deletions

6993
data/abgb.json Normal file

File diff suppressed because it is too large Load Diff

6983
data/urhg.json Normal file

File diff suppressed because it is too large Load Diff

View File

@ -185,4 +185,34 @@ mod tests {
assert!(wrapper.is_ok());
}
#[test]
fn deserialize_abgb_success() {
let mut file = File::open("data/abgb.json").unwrap();
let mut json = String::new();
file.read_to_string(&mut json).unwrap();
let wrapper: serde_json::Result<Wrapper> = serde_json::from_str(&json);
if wrapper.is_err() {
let dbg = wrapper.as_ref().err().unwrap();
println!("{dbg:#?}");
}
assert!(wrapper.is_ok());
}
#[test]
fn deserialize_urhg_success() {
let mut file = File::open("data/urhg.json").unwrap();
let mut json = String::new();
file.read_to_string(&mut json).unwrap();
let wrapper: serde_json::Result<Wrapper> = serde_json::from_str(&json);
if wrapper.is_err() {
let dbg = wrapper.as_ref().err().unwrap();
println!("{dbg:#?}");
}
assert!(wrapper.is_ok());
}
}