use wander::{preludes::common, run, WanderValue};
#[test]
fn read_write_test_strings() {
let input = vec![
"\"\"".to_owned(),
"\"hello, world\"".to_owned(),
"\"hello,\\nworld\"".to_owned(),
];
let res: Vec<WanderValue<String>> = input
.iter()
.map(|s| run(s, &mut common()).unwrap())
.collect();
let res: Vec<String> = res.iter().map(|s| format!("{s}")).collect();
assert_eq!(input, res);
}
#[test]
fn read_write_test_identifiers() {
let input = vec![
"<a>".to_owned(),
"<123>".to_owned(),
"<https://github.com/almibe/ligature-rs>".to_owned(),
];
let res: Vec<WanderValue<String>> = input
.iter()
.map(|s| run(s, &mut common()).unwrap())
.collect();
let res: Vec<String> = res.iter().map(|s| format!("{s}")).collect();
assert_eq!(input, res);
}