fix(parser): count rows in the debug log from 0

This commit is contained in:
Andrew Hlynskyi 2021-07-15 08:26:14 +03:00
parent 9cb732859f
commit 7f538170bf
2 changed files with 9 additions and 4 deletions

View file

@ -63,9 +63,14 @@ fn test_parsing_with_logging() {
)));
assert!(messages.contains(&(LogType::Lex, "skip character:' '".to_string())));
let mut row_starts_from_0 = false;
for (_, m) in &messages {
assert!(!m.contains("row:0"));
if m.contains("row:0") {
row_starts_from_0 = true;
break;
}
}
assert!(row_starts_from_0);
}
#[test]