Swich back to assert_eq! for token stream tests.

This commit is contained in:
Stephen Chung 2020-09-17 11:37:23 +08:00 committed by J Henry Waugh
parent c692cd7e35
commit 5e4ba9c016
2 changed files with 8 additions and 3 deletions

View File

@ -245,6 +245,8 @@ mod generate_tests {
false false
} }
}); });
eprintln!("actual != expected, diverge at char {}", counter);
/*
let (actual_diff, expected_diff) = { let (actual_diff, expected_diff) = {
let mut actual_diff = String::new(); let mut actual_diff = String::new();
let mut expected_diff = String::new(); let mut expected_diff = String::new();
@ -254,11 +256,12 @@ mod generate_tests {
} }
(actual_diff, expected_diff) (actual_diff, expected_diff)
}; };
eprintln!("actual != expected, diverge at char {}", counter);
eprintln!(" actual: {}", actual_diff); eprintln!(" actual: {}", actual_diff);
eprintln!("expected: {}", expected_diff); eprintln!("expected: {}", expected_diff);
assert!(false); assert!(false);
*/
} }
assert_eq!(actual, expected);
} }
#[test] #[test]

View File

@ -226,6 +226,8 @@ mod generate_tests {
false false
} }
}); });
eprintln!("actual != expected, diverge at char {}", counter);
/*
let (actual_diff, expected_diff) = { let (actual_diff, expected_diff) = {
let mut actual_diff = String::new(); let mut actual_diff = String::new();
let mut expected_diff = String::new(); let mut expected_diff = String::new();
@ -235,12 +237,12 @@ mod generate_tests {
} }
(actual_diff, expected_diff) (actual_diff, expected_diff)
}; };
eprintln!("actual != expected, diverge at char {}", counter);
eprintln!(" actual: {}", actual_diff); eprintln!(" actual: {}", actual_diff);
eprintln!("expected: {}", expected_diff); eprintln!("expected: {}", expected_diff);
assert!(false); assert!(false);
*/
} }
//assert_eq!(actual, expected); assert_eq!(actual, expected);
} }
#[test] #[test]